# mod $define(mod_marp=) # Environment variables $define(v_basis_height=500) $define(v_font_default=24) $define(v_thead_default=18) $define(v_tbody_default=14) # Macros # Set font family $define(font,a_font_names=) # Substitue class name with marp compatible class form # white space between _class: and $1 is necessary $define(m_class,a_class=) # Subsitue with markdown compatible image form # Convert contents into single lined html # This was intended for multi line support in csv table # TODO # This is a crude conversion, not real conversion $define(m_newline_to_br,a_scell=$regex($a_scell(),$nl(),
)) # ========== # User interface macros # Basic syntax macros # Headers $define(h1,a_content=# $a_content()) $define(h2,a_content=## $a_content()) $define(h3,a_content=### $a_content()) $define(h4,a_content=#### $a_content()) $define(h5,a_content=##### $a_content()) # Bold $define(b,a_content=**$a_content()**) # Italic $define(i,a_content=*$a_content()*) # ItalicBold $define(bi,a_content=***$a_content()***) # Strike through $define(st,a_content=~~$a_content()~~) # Underline $define(ud,a_content=__$a_content()__) # Indentation # WARNING : Single spaces between if else bracket end and macro define bracket end # is necessary, do not erase it. $define(idt,a_count=$forloop(2,$a_count(), )) # Lists # Unordered List # Emtpry ul is same with level 1 $define(ul,a_count=$forloop(2,$a_count(), )*) # Ordered list $define(ol,a_count=$forloop(2,$a_count(), )1.) # Paragraph $define(p,a_content=

$a_content()

) # New page $define(newpage= --- ) # MACRO >>> Get style files' name and paste the content # Usage : # styles(image,layout) $define(styles,a_styles= ) # Multiline support csv table related macros # Refer macro.md for general usage # Start table $define(tstart=) # Set table font size $define(tfont,a_header_size a_body_size=) # Set table header $define(theader,a_content= $foreach($a_content*(), ) ) # Set table row $define(trow,a_content= $foreach($a_content*(),\* $m_newline_to_br()*\) ) # end table $define(tend=
$:
$:
) # URL $define(url,a_src a_text=[$a_text()]($a_src())) # $2 is alternate text, $1 is image url # Image substitue macros $define(image,a_url= ![Image not found]($a_url()) ) # Make Set img's max-width with given arguments $define(simage,a_src a_max_width=
) # MACRO >>> Text macro that also sets font size for the text # Example : # text(26, yatti yatta) $define(text,a_font_size a_content=
$trim($a_content())
) # MACRO >>> Flex box macro that makes div a flex display # Intended for usage with split screen $define(fbox,a_content=
$trim($a_content())
) # MACRO >>> Flex box with given font size $define(ffbox,a_font_size a_content=
$trim($a_content())
) # Class related macros # Macro >>> set table of contents $define(toc,a_text a_goto=
    $a_text()
) # MACRO >>> Set title class into slide and type title, author text at the same time $define(title,a_title a_subtitle=$m_class(title) # $a_title() ## $a_subtitle() ) # MACRO >>> Set any class of given arguments $define(class,a_class=$m_class($regex($a_class*(),\*,*\, ))) # Split screen related macros # MACRO >>> Start left pane $define(left=
) # MACRO >>> Start right pane $define(right=
) # MACRO >>> End split screen $define(end=
) # Center macro $define(center,a_content=
$a_content()
)