6497
This commit is contained in:
parent
fb778c1d86
commit
d7394beca6
|
@ -100,25 +100,35 @@ $render-normal:flush-buffered-newline: {
|
||||||
}
|
}
|
||||||
## end soft newline support
|
## end soft newline support
|
||||||
|
|
||||||
# if (c == '*') switch to bold
|
$render-normal:whitespace-separated-regions: {
|
||||||
compare c, 0x2a # '*'
|
# if previous-char wasn't whitespace, skip this block
|
||||||
{
|
{
|
||||||
break-if-!=
|
compare previous-char, 0x20 # space
|
||||||
start-bold
|
break-if-=
|
||||||
render-until-asterisk fs, state
|
compare previous-char, 0xa # newline
|
||||||
normal-text
|
break-if-=
|
||||||
break $render-normal:loop-body
|
break $render-normal:whitespace-separated-regions
|
||||||
}
|
}
|
||||||
# if (c == '_') switch to bold
|
# if (c == '*') switch to bold
|
||||||
compare c, 0x5f # '_'
|
compare c, 0x2a # '*'
|
||||||
{
|
{
|
||||||
break-if-!=
|
break-if-!=
|
||||||
start-color 0xec, 7 # 236 = darkish gray
|
start-bold
|
||||||
start-bold
|
render-until-asterisk fs, state
|
||||||
render-until-underscore fs, state
|
normal-text
|
||||||
reset-formatting
|
break $render-normal:loop-body
|
||||||
start-color 0xec, 7 # 236 = darkish gray
|
}
|
||||||
break $render-normal:loop-body
|
# if (c == '_') switch to bold
|
||||||
|
compare c, 0x5f # '_'
|
||||||
|
{
|
||||||
|
break-if-!=
|
||||||
|
start-color 0xec, 7 # 236 = darkish gray
|
||||||
|
start-bold
|
||||||
|
render-until-underscore fs, state
|
||||||
|
reset-formatting
|
||||||
|
start-color 0xec, 7 # 236 = darkish gray
|
||||||
|
break $render-normal:loop-body
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#
|
#
|
||||||
add-char state, c
|
add-char state, c
|
||||||
|
|
Loading…
Reference in New Issue