commit postpiece stuff
This commit is contained in:
parent
120aa3ec3c
commit
4a88ec6f62
21
postercise/LICENSE
Normal file
21
postercise/LICENSE
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2024 Daniel King
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in all
|
||||||
|
copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.
|
||||||
129
postercise/README.md
Normal file
129
postercise/README.md
Normal file
@ -0,0 +1,129 @@
|
|||||||
|
# Postercise
|
||||||
|
|
||||||
|
**Postercise** allows users to easily create academic research posters with different themes using [Typst](https://typst.app).
|
||||||
|
|
||||||
|

|
||||||
|

|
||||||
|

|
||||||
|
|
||||||
|
|
||||||
|
## Getting started
|
||||||
|
|
||||||
|
You can get **Postercise** from the official package repository by entering the following.
|
||||||
|
```typ
|
||||||
|
#import "@preview/postercise:0.2.0": *
|
||||||
|
```
|
||||||
|
|
||||||
|
Another option is to use **Postercise** as a local module by downloading the package files into your project folder.
|
||||||
|
|
||||||
|
Next you will need to import a theme, set up the page and font, and call the `show` command.
|
||||||
|
```typ
|
||||||
|
#import themes.basic: *
|
||||||
|
|
||||||
|
#set page(width: 24in, height: 18in)
|
||||||
|
#set text(size: 24pt)
|
||||||
|
|
||||||
|
#show: theme
|
||||||
|
```
|
||||||
|
|
||||||
|
To add content to the poster, use the `poster-content` command.
|
||||||
|
|
||||||
|
```typ
|
||||||
|
#poster-content()[
|
||||||
|
// Content goes here
|
||||||
|
]
|
||||||
|
```
|
||||||
|
|
||||||
|
There are a few options for types of content that should be added inside the `poster-content`. The body of the poster can be typed as normal, or two box styles are provided to headings and/or highlight content in special ways.
|
||||||
|
|
||||||
|
```typ
|
||||||
|
#normal-box[]
|
||||||
|
#focus-box[]
|
||||||
|
```
|
||||||
|
|
||||||
|
Basic information like title and authors is placed as options using the `poster-header` script.
|
||||||
|
|
||||||
|
```typ
|
||||||
|
#poster-header(
|
||||||
|
title: [Title],
|
||||||
|
authors: [Author],
|
||||||
|
)
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
Finally, additional content can be added to the footer with the `poster-footer` script.
|
||||||
|
```typ
|
||||||
|
#poster-footer[]
|
||||||
|
```
|
||||||
|
|
||||||
|
Again, as a reminder, all of these scripts should be called from inside of the `poster-content` block.
|
||||||
|
|
||||||
|
Using these commands, it is easy to produce posters like the following:
|
||||||
|

|
||||||
|
|
||||||
|
## More details
|
||||||
|
### `themes`
|
||||||
|
Currently, 3 themes are available. Use one of these `import` commands to load that theme.
|
||||||
|
```typ
|
||||||
|
#import themes.basic: *
|
||||||
|
#import themes.better: *
|
||||||
|
#import themes.boxes: *
|
||||||
|
```
|
||||||
|
|
||||||
|
### `show: theme.with()`
|
||||||
|
Theme options allow you to adjust the color scheme, as well as the color and size of the content in the header. The defaults are shown below. (The 'better.typ' theme defaults to different titletext color and size.)
|
||||||
|
```typ
|
||||||
|
#show: theme.with(
|
||||||
|
primary-color: rgb(28,55,103), // Dark blue
|
||||||
|
background-color: white,
|
||||||
|
accent-color: rgb(243,163,30), // Yellow
|
||||||
|
titletext-color: white,
|
||||||
|
titletext-size: 2em,
|
||||||
|
)
|
||||||
|
```
|
||||||
|
|
||||||
|
### `poster-content()[]`
|
||||||
|
The only option for the main content is the number of columns. This defaults to 3 for most themes. For the "better.typ" theme, there is 1 column and content is placed in the leftmost column below `poster-header`.
|
||||||
|
```typ
|
||||||
|
#poster-content(col: 3)[
|
||||||
|
// Content goes here
|
||||||
|
]
|
||||||
|
```
|
||||||
|
|
||||||
|
### `normal-box()[]` and `focus-box()[]`
|
||||||
|
By default, these boxes use the no fill and the accent-color fill, respectively. However, they do accept color as an option, and will add a primary-color stroke around the box if a color is given. For the "better.typ" theme, use `focus-box` to place content in the center column.
|
||||||
|
```typ
|
||||||
|
#normal-box(color: none)[
|
||||||
|
// Content
|
||||||
|
]
|
||||||
|
|
||||||
|
#focus-box(color: none)[
|
||||||
|
// Content
|
||||||
|
]
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
### `poster-header()`
|
||||||
|
Available options for the poster header for most themes are shown below. Note that logos should be explicitly labeled as images. Logos are not currently displayed in the header in the "better.typ" theme.
|
||||||
|
```typ
|
||||||
|
#poster-header(
|
||||||
|
title: [Title],
|
||||||
|
subtitle: [Subtitle],
|
||||||
|
author: [Author],
|
||||||
|
affiliation: [Affiliation],
|
||||||
|
logo-1: image("placeholder.png")
|
||||||
|
logo-2: image("placeholder.png")
|
||||||
|
)
|
||||||
|
```
|
||||||
|
|
||||||
|
### `poster-footer[]`
|
||||||
|
This command does not currently have any extra options. The content is typically placed at the bottom of the poster, but it is placed in the rightmost column for the "better.typ" theme.
|
||||||
|
```typ
|
||||||
|
#poster-footer[
|
||||||
|
// Content
|
||||||
|
]
|
||||||
|
```
|
||||||
|
|
||||||
|
## Known Issues
|
||||||
|
- The bibliography does not work properly and must be done manually
|
||||||
|
|
||||||
80
postercise/examples/basic-example.typ
Normal file
80
postercise/examples/basic-example.typ
Normal file
@ -0,0 +1,80 @@
|
|||||||
|
// Import a theme
|
||||||
|
#import "../postercise.typ": *
|
||||||
|
#import themes.basic: *
|
||||||
|
|
||||||
|
// Set up paper dimensions and text
|
||||||
|
#set page(width: 24in, height: 18in)
|
||||||
|
#set text(size: 28pt)
|
||||||
|
|
||||||
|
// Set up colors
|
||||||
|
#show: theme.with()
|
||||||
|
|
||||||
|
// Add content
|
||||||
|
#poster-content[
|
||||||
|
|
||||||
|
// Add title, subtitle, author, affiliation, logos
|
||||||
|
#poster-header(
|
||||||
|
title: [Title of Research Project:],
|
||||||
|
subtitle: [Subtitle],
|
||||||
|
authors: [List of Authors],
|
||||||
|
logo-1: image("emu-logo.png")
|
||||||
|
)
|
||||||
|
|
||||||
|
// Include content in the footer
|
||||||
|
#poster-footer[
|
||||||
|
#set text(fill: white)
|
||||||
|
_Additional information_
|
||||||
|
]
|
||||||
|
|
||||||
|
// normal-box is used to create sections
|
||||||
|
#normal-box()[
|
||||||
|
= Background
|
||||||
|
#lorem(20)
|
||||||
|
]
|
||||||
|
|
||||||
|
// color can be overwritten
|
||||||
|
#normal-box(color: aqua)[
|
||||||
|
= Methods
|
||||||
|
#lorem(20)
|
||||||
|
$ gamma = 1/2 alpha beta^2 $
|
||||||
|
#lorem(15)
|
||||||
|
#figure(image("placeholder.png", width: 50%),
|
||||||
|
caption: [_Fig. 1: Sample Figure_])
|
||||||
|
]
|
||||||
|
|
||||||
|
#normal-box()[
|
||||||
|
= Results
|
||||||
|
#lorem(20)
|
||||||
|
#figure(image("placeholder.png", width: 50%),
|
||||||
|
caption: [_Fig. 2: Sample Results_])
|
||||||
|
#lorem(20)
|
||||||
|
#figure(table(columns: 3,
|
||||||
|
rows: 2,
|
||||||
|
fill: white, stroke: 0.0625em,
|
||||||
|
[*a*], [*b*], [*c*],
|
||||||
|
[1], [2], [3]),
|
||||||
|
caption: [_Table 1: Sample Table_])
|
||||||
|
]
|
||||||
|
#lorem(20)
|
||||||
|
|
||||||
|
#focus-box()[
|
||||||
|
= Key Findings
|
||||||
|
+ #lorem(5)
|
||||||
|
+ #lorem(4)
|
||||||
|
+ #lorem(8)
|
||||||
|
]
|
||||||
|
|
||||||
|
#normal-box()[
|
||||||
|
= Discussion
|
||||||
|
#lorem(30)
|
||||||
|
]
|
||||||
|
|
||||||
|
// Content can also be added without boxes for more flexible formatting
|
||||||
|
= Acknowledgements
|
||||||
|
The authors wish to thank those providing guidance, support, and funding.
|
||||||
|
|
||||||
|
= References
|
||||||
|
#set text(size: 0.8em)
|
||||||
|
+ #lorem(8)
|
||||||
|
+ #lorem(12)
|
||||||
|
]
|
||||||
66
postercise/examples/better-example.typ
Normal file
66
postercise/examples/better-example.typ
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
// Import a theme
|
||||||
|
#import "../postercise.typ": *
|
||||||
|
#import themes.better: *
|
||||||
|
|
||||||
|
// Set up paper dimensions and text
|
||||||
|
#set page(width: 24in, height: 18in)
|
||||||
|
#set text(font: "Calibri", size: 24pt)
|
||||||
|
|
||||||
|
// Set up colors
|
||||||
|
#show: theme.with()
|
||||||
|
|
||||||
|
// Add content
|
||||||
|
#poster-content[
|
||||||
|
|
||||||
|
// Add title, subtitle, author, affiliation, logos
|
||||||
|
#poster-header(
|
||||||
|
title: [Title of Research Project:],
|
||||||
|
subtitle: [Subtitle],
|
||||||
|
authors: [List of Authors],
|
||||||
|
logo-1: image("placeholder.png")
|
||||||
|
)
|
||||||
|
|
||||||
|
// Include content in the footer
|
||||||
|
#poster-footer[
|
||||||
|
|
||||||
|
_Additional information_
|
||||||
|
= Acknowledgements
|
||||||
|
The authors wish to thank those providing guidance, support, and funding.
|
||||||
|
|
||||||
|
= References
|
||||||
|
#set text(size: 0.8em)
|
||||||
|
+ #lorem(8)
|
||||||
|
+ #lorem(12)
|
||||||
|
|
||||||
|
#figure(image("emu-logo.png", width: 60%))
|
||||||
|
]
|
||||||
|
|
||||||
|
= Research Question
|
||||||
|
#lorem(10)
|
||||||
|
|
||||||
|
= Methods
|
||||||
|
#lorem(10)
|
||||||
|
|
||||||
|
- #lorem(4)
|
||||||
|
- #lorem(6)
|
||||||
|
|
||||||
|
// A normal box can be used to highlight
|
||||||
|
#normal-box()[
|
||||||
|
= Results
|
||||||
|
#lorem(10)
|
||||||
|
|
||||||
|
#figure(image("placeholder.png", width: 50%),
|
||||||
|
caption: [_Fig. 1: Sample Results_])
|
||||||
|
]
|
||||||
|
|
||||||
|
// Focus-box is used for the main findings
|
||||||
|
#focus-box()[
|
||||||
|
= Key Findings
|
||||||
|
#lorem(20)
|
||||||
|
|
||||||
|
]
|
||||||
|
|
||||||
|
= Discussion
|
||||||
|
#lorem(20)
|
||||||
|
|
||||||
|
]
|
||||||
80
postercise/examples/boxes-example.typ
Normal file
80
postercise/examples/boxes-example.typ
Normal file
@ -0,0 +1,80 @@
|
|||||||
|
// Import a theme
|
||||||
|
#import "../postercise.typ": *
|
||||||
|
#import themes.boxes: *
|
||||||
|
|
||||||
|
// Set up paper dimensions and text
|
||||||
|
#set page(width: 24in, height: 18in)
|
||||||
|
#set text(font: "Calibri", size: 28pt)
|
||||||
|
|
||||||
|
// Set up colors
|
||||||
|
#show: theme.with()
|
||||||
|
|
||||||
|
// Add content
|
||||||
|
#poster-content[
|
||||||
|
|
||||||
|
// Add title, subtitle, author, affiliation, logos
|
||||||
|
#poster-header(
|
||||||
|
title: [Title of Research Project:],
|
||||||
|
subtitle: [Subtitle],
|
||||||
|
authors: [List of Authors],
|
||||||
|
logo-1: image("emu-logo.png")
|
||||||
|
)
|
||||||
|
|
||||||
|
// Include content in the footer
|
||||||
|
#poster-footer[
|
||||||
|
#set text(fill: black)
|
||||||
|
_Additional information_
|
||||||
|
]
|
||||||
|
|
||||||
|
// normal-box is used to create sections
|
||||||
|
#normal-box()[
|
||||||
|
= Background
|
||||||
|
#lorem(20)
|
||||||
|
]
|
||||||
|
|
||||||
|
// color can be overwritten
|
||||||
|
#normal-box(color: aqua)[
|
||||||
|
= Methods
|
||||||
|
#lorem(20)
|
||||||
|
$ gamma = 1/2 alpha beta^2 $
|
||||||
|
#lorem(15)
|
||||||
|
#figure(image("placeholder.png", width: 50%),
|
||||||
|
caption: [_Fig. 1: Sample Figure_])
|
||||||
|
]
|
||||||
|
|
||||||
|
#normal-box()[
|
||||||
|
= Results
|
||||||
|
#lorem(20)
|
||||||
|
#figure(image("placeholder.png", width: 50%),
|
||||||
|
caption: [_Fig. 2: Sample Results_])
|
||||||
|
#lorem(20)
|
||||||
|
#figure(table(columns: 3,
|
||||||
|
rows: 2,
|
||||||
|
fill: white, stroke: 0.0625em,
|
||||||
|
[*a*], [*b*], [*c*],
|
||||||
|
[1], [2], [3]),
|
||||||
|
caption: [_Table 1: Sample Table_])
|
||||||
|
]
|
||||||
|
#lorem(20)
|
||||||
|
|
||||||
|
#focus-box()[
|
||||||
|
= Key Findings
|
||||||
|
+ #lorem(5)
|
||||||
|
+ #lorem(4)
|
||||||
|
+ #lorem(8)
|
||||||
|
]
|
||||||
|
|
||||||
|
#normal-box()[
|
||||||
|
= Discussion
|
||||||
|
#lorem(30)
|
||||||
|
]
|
||||||
|
|
||||||
|
// Content can also be added without boxes for more flexible formatting
|
||||||
|
= Acknowledgements
|
||||||
|
The authors wish to thank those providing guidance, support, and funding.
|
||||||
|
|
||||||
|
= References
|
||||||
|
#set text(size: 0.8em)
|
||||||
|
+ #lorem(8)
|
||||||
|
+ #lorem(12)
|
||||||
|
]
|
||||||
BIN
postercise/examples/emu-logo.png
Normal file
BIN
postercise/examples/emu-logo.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 24 KiB |
BIN
postercise/examples/placeholder.png
Normal file
BIN
postercise/examples/placeholder.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.5 KiB |
BIN
postercise/examples/postercise-examples.png
Normal file
BIN
postercise/examples/postercise-examples.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 643 KiB |
11
postercise/typst.toml
Normal file
11
postercise/typst.toml
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
[package]
|
||||||
|
name = "postercise"
|
||||||
|
version = "0.2.0"
|
||||||
|
entrypoint = "postercise.typ"
|
||||||
|
authors = ["Daniel King"]
|
||||||
|
license = "MIT"
|
||||||
|
description = "Postercise allows users to easily create academic research posters with different themes using Typst."
|
||||||
|
repository = "https://github.com/dangh3014/postercise/"
|
||||||
|
exclude = ["examples/*"]
|
||||||
|
keywords = ["academic", "research", "poster", "presentation", "template", "theme"]
|
||||||
|
categories = ["poster", "presentation"]
|
||||||
Loading…
x
Reference in New Issue
Block a user