mirror of https://github.com/eyhc1/rendercv.git
add header margin options
This commit is contained in:
parent
f64bc27ef6
commit
260e7ba4dd
|
@ -417,6 +417,26 @@ class ClassicThemeHighlightsAreaMargins(BaseModel):
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
class ClassicThemeHeaderMargins(BaseModel):
|
||||||
|
"""This class stores the margins of the header for the classic theme."""
|
||||||
|
|
||||||
|
vertical_between_name_and_connections: LaTeXDimension = Field(
|
||||||
|
default="0.2 cm",
|
||||||
|
title="Vertical Margin Between the Name and Connections",
|
||||||
|
description=(
|
||||||
|
"The vertical margin between the name of the person and the connections."
|
||||||
|
),
|
||||||
|
)
|
||||||
|
bottom: LaTeXDimension = Field(
|
||||||
|
default="0.2 cm",
|
||||||
|
title="Bottom Margin",
|
||||||
|
description=(
|
||||||
|
"The bottom margin of the header, i.e., the vertical margin between the"
|
||||||
|
" connections and the first section title."
|
||||||
|
),
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
class ClassicThemeMargins(BaseModel):
|
class ClassicThemeMargins(BaseModel):
|
||||||
"""This class stores the margins for the classic theme."""
|
"""This class stores the margins for the classic theme."""
|
||||||
|
|
||||||
|
@ -440,6 +460,11 @@ class ClassicThemeMargins(BaseModel):
|
||||||
title="Highlights Area Margins",
|
title="Highlights Area Margins",
|
||||||
description="Highlights area margins for the classic theme.",
|
description="Highlights area margins for the classic theme.",
|
||||||
)
|
)
|
||||||
|
header: ClassicThemeHeaderMargins = Field(
|
||||||
|
default=ClassicThemeHeaderMargins(),
|
||||||
|
title="Header Margins",
|
||||||
|
description="Header margins for the classic theme.",
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
class ClassicThemeOptions(BaseModel):
|
class ClassicThemeOptions(BaseModel):
|
||||||
|
@ -463,7 +488,7 @@ class ClassicThemeOptions(BaseModel):
|
||||||
)
|
)
|
||||||
|
|
||||||
date_and_location_width: LaTeXDimension = Field(
|
date_and_location_width: LaTeXDimension = Field(
|
||||||
default="3.6 cm",
|
default="4.1 cm",
|
||||||
title="Date and Location Column Width",
|
title="Date and Location Column Width",
|
||||||
description="The width of the date and location column.",
|
description="The width of the date and location column.",
|
||||||
)
|
)
|
||||||
|
|
|
@ -135,6 +135,7 @@
|
||||||
((* endif *))
|
((* endif *))
|
||||||
|
|
||||||
<<header(name=cv.name, connections=cv.connections)|indent(4)>>
|
<<header(name=cv.name, connections=cv.connections)|indent(4)>>
|
||||||
|
|
||||||
((* if cv.summary is not none *))
|
((* if cv.summary is not none *))
|
||||||
\section{Summary}
|
\section{Summary}
|
||||||
{
|
{
|
||||||
|
|
|
@ -4,6 +4,8 @@
|
||||||
\Huge
|
\Huge
|
||||||
\textbf{<<name>>}
|
\textbf{<<name>>}
|
||||||
|
|
||||||
|
\vspace{<<theme_options.margins.header.vertical_between_name_and_connections>>}
|
||||||
|
|
||||||
\normalsize
|
\normalsize
|
||||||
((* for connection in connections *))
|
((* for connection in connections *))
|
||||||
<<print_connections[connection.name|replace(" ", "")](connection.value, connection.url)>>
|
<<print_connections[connection.name|replace(" ", "")](connection.value, connection.url)>>
|
||||||
|
@ -12,4 +14,6 @@
|
||||||
((* endif *))
|
((* endif *))
|
||||||
((* endfor *))
|
((* endfor *))
|
||||||
\end{header}
|
\end{header}
|
||||||
|
|
||||||
|
\vspace{<<theme_options.margins.header.bottom>>}
|
||||||
((* endmacro *))
|
((* endmacro *))
|
46
schema.json
46
schema.json
|
@ -21,6 +21,27 @@
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"additionalProperties": false
|
"additionalProperties": false
|
||||||
},
|
},
|
||||||
|
"ClassicThemeHeaderMargins": {
|
||||||
|
"properties": {
|
||||||
|
"vertical_between_name_and_connections": {
|
||||||
|
"default": "0.2 cm",
|
||||||
|
"description": "The vertical margin between the name of the person and the connections.",
|
||||||
|
"pattern": "\\d+\\.?\\d* *(cm|in|pt|mm|ex|em)",
|
||||||
|
"title": "Vertical Margin Between the Name and Connections",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"bottom": {
|
||||||
|
"default": "0.2 cm",
|
||||||
|
"description": "The bottom margin of the header, i.e., the vertical margin between the connections and the first section title.",
|
||||||
|
"pattern": "\\d+\\.?\\d* *(cm|in|pt|mm|ex|em)",
|
||||||
|
"title": "Bottom Margin",
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"title": "ClassicThemeHeaderMargins",
|
||||||
|
"type": "object",
|
||||||
|
"additionalProperties": false
|
||||||
|
},
|
||||||
"ClassicThemeHighlightsAreaMargins": {
|
"ClassicThemeHighlightsAreaMargins": {
|
||||||
"properties": {
|
"properties": {
|
||||||
"top": {
|
"top": {
|
||||||
|
@ -105,6 +126,19 @@
|
||||||
},
|
},
|
||||||
"description": "Highlights area margins for the classic theme.",
|
"description": "Highlights area margins for the classic theme.",
|
||||||
"title": "Highlights Area Margins"
|
"title": "Highlights Area Margins"
|
||||||
|
},
|
||||||
|
"header": {
|
||||||
|
"allOf": [
|
||||||
|
{
|
||||||
|
"$ref": "#/$defs/ClassicThemeHeaderMargins"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"default": {
|
||||||
|
"bottom": "0.2 cm",
|
||||||
|
"vertical_between_name_and_connections": "0.2 cm"
|
||||||
|
},
|
||||||
|
"description": "Header margins for the classic theme.",
|
||||||
|
"title": "Header Margins"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"title": "ClassicThemeMargins",
|
"title": "ClassicThemeMargins",
|
||||||
|
@ -127,7 +161,7 @@
|
||||||
"type": "string"
|
"type": "string"
|
||||||
},
|
},
|
||||||
"date_and_location_width": {
|
"date_and_location_width": {
|
||||||
"default": "3.6 cm",
|
"default": "4.1 cm",
|
||||||
"description": "The width of the date and location column.",
|
"description": "The width of the date and location column.",
|
||||||
"pattern": "\\d+\\.?\\d* *(cm|in|pt|mm|ex|em)",
|
"pattern": "\\d+\\.?\\d* *(cm|in|pt|mm|ex|em)",
|
||||||
"title": "Date and Location Column Width",
|
"title": "Date and Location Column Width",
|
||||||
|
@ -169,6 +203,10 @@
|
||||||
"left_and_right": "0.2 cm",
|
"left_and_right": "0.2 cm",
|
||||||
"vertical_between": "0.12 cm"
|
"vertical_between": "0.12 cm"
|
||||||
},
|
},
|
||||||
|
"header": {
|
||||||
|
"bottom": "0.2 cm",
|
||||||
|
"vertical_between_name_and_connections": "0.2 cm"
|
||||||
|
},
|
||||||
"highlights_area": {
|
"highlights_area": {
|
||||||
"left": "0.6 cm",
|
"left": "0.6 cm",
|
||||||
"top": "0.12 cm",
|
"top": "0.12 cm",
|
||||||
|
@ -1561,12 +1599,16 @@
|
||||||
"font": "SourceSans3",
|
"font": "SourceSans3",
|
||||||
"font_size": "10pt",
|
"font_size": "10pt",
|
||||||
"options": {
|
"options": {
|
||||||
"date_and_location_width": "3.6 cm",
|
"date_and_location_width": "4.1 cm",
|
||||||
"margins": {
|
"margins": {
|
||||||
"entry_area": {
|
"entry_area": {
|
||||||
"left_and_right": "0.2 cm",
|
"left_and_right": "0.2 cm",
|
||||||
"vertical_between": "0.12 cm"
|
"vertical_between": "0.12 cm"
|
||||||
},
|
},
|
||||||
|
"header": {
|
||||||
|
"bottom": "0.2 cm",
|
||||||
|
"vertical_between_name_and_connections": "0.2 cm"
|
||||||
|
},
|
||||||
"highlights_area": {
|
"highlights_area": {
|
||||||
"left": "0.6 cm",
|
"left": "0.6 cm",
|
||||||
"top": "0.12 cm",
|
"top": "0.12 cm",
|
||||||
|
|
|
@ -109,7 +109,7 @@
|
||||||
\LenToUnit{\paperwidth-1.35 cm-0.2 cm+0.05cm},
|
\LenToUnit{\paperwidth-1.35 cm-0.2 cm+0.05cm},
|
||||||
\LenToUnit{\paperheight-0.675 cm}
|
\LenToUnit{\paperheight-0.675 cm}
|
||||||
){\vtop{{\null}\makebox[0pt][c]{
|
){\vtop{{\null}\makebox[0pt][c]{
|
||||||
\small\color{gray}\textit{Last updated on November 20, 2023}\hspace{\widthof{Last updated on November 20, 2023}}
|
\small\color{gray}\textit{Last updated on November 22, 2023}\hspace{\widthof{Last updated on November 22, 2023}}
|
||||||
}}}%
|
}}}%
|
||||||
}%
|
}%
|
||||||
}%
|
}%
|
||||||
|
@ -126,6 +126,8 @@
|
||||||
\Huge
|
\Huge
|
||||||
\textbf{John Doe}
|
\textbf{John Doe}
|
||||||
|
|
||||||
|
\vspace{0.2 cm}
|
||||||
|
|
||||||
\normalsize
|
\normalsize
|
||||||
\mbox{{\small\faMapMarker*}\hspace{0.13cm}TX, USA}
|
\mbox{{\small\faMapMarker*}\hspace{0.13cm}TX, USA}
|
||||||
\hspace{0.5cm}
|
\hspace{0.5cm}
|
||||||
|
@ -140,6 +142,9 @@
|
||||||
\mbox{\hrefWithoutArrow{https://www.linkedin.com/in/johndoe}{{\small\faLinkedinIn}\hspace{0.13cm}johndoe}}
|
\mbox{\hrefWithoutArrow{https://www.linkedin.com/in/johndoe}{{\small\faLinkedinIn}\hspace{0.13cm}johndoe}}
|
||||||
\end{header}
|
\end{header}
|
||||||
|
|
||||||
|
\vspace{0.2 cm}
|
||||||
|
|
||||||
|
|
||||||
\section{Summary}
|
\section{Summary}
|
||||||
{
|
{
|
||||||
\raggedright
|
\raggedright
|
||||||
|
|
Loading…
Reference in New Issue