- Update gitignore - Rewrite blocks text - Add custom "Отступы от края страницы"
This commit is contained in:
@@ -15,6 +15,22 @@ MARGIN_RIGHT = Mm(10)
|
||||
MARGIN_TOP = Mm(20)
|
||||
MARGIN_BOTTOM = Mm(20)
|
||||
|
||||
# mirea / pis_custom — 30/10/20/20; paco_custom — форма ПАЦО 20/20/20/20
|
||||
MARGIN_PRESETS = {
|
||||
"mirea": (Mm(30), Mm(10), Mm(20), Mm(20)),
|
||||
"pis_custom": (Mm(30), Mm(10), Mm(20), Mm(20)),
|
||||
}
|
||||
|
||||
|
||||
def apply_margin_preset(preset: str) -> None:
|
||||
"""Switch active page margins used by apply_section_geometry / content_size."""
|
||||
global MARGIN_LEFT, MARGIN_RIGHT, MARGIN_TOP, MARGIN_BOTTOM
|
||||
left, right, top, bottom = MARGIN_PRESETS.get(preset, MARGIN_PRESETS["mirea"])
|
||||
MARGIN_LEFT = left
|
||||
MARGIN_RIGHT = right
|
||||
MARGIN_TOP = top
|
||||
MARGIN_BOTTOM = bottom
|
||||
|
||||
A4_SHORT = Mm(210)
|
||||
A4_LONG = Mm(297)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user