1
1
Fork 0
mirror of https://github.com/QB64-Phoenix-Edition/QB64pe.git synced 2024-07-01 15:00:38 +00:00

Implement handling for 'Parameter' template

This commit is contained in:
Roland Heyder 2022-06-07 00:50:13 +02:00
parent a4ffe65525
commit 8d8fc3b7fb

View file

@ -578,7 +578,9 @@ SUB WikiParse (a$) 'Wiki page interpret
wla$ = wikiLookAhead$(a$, i + 1, "}}")
cb = 0: i = i + LEN(wla$) + 2 'after 1st, ignore all further template parameters
ELSEIF c$(2) = "}}" THEN
IF LCASE$(LEFT$(cb$, 5)) = "small" THEN
IF cb$ = "Parameter" THEN
Help_Italic = 0: col = Help_Col
ELSEIF LCASE$(LEFT$(cb$, 5)) = "small" THEN
IF ASC(cb$, 6) = 196 THEN
Help_AddTxt " " + STRING$(Help_ww - Help_Pos, 196), 15, 0
Help_BG_Col = 0: col = Help_Col
@ -597,7 +599,7 @@ SUB WikiParse (a$) 'Wiki page interpret
'Recommended order of main page sections (h2) with it's considered sub-sections (h3)
IF cb$ = "PageSyntax" THEN cbo$ = "Syntax:"
IF cb$ = "PageLegacySupport" THEN cbo$ = "Legacy support" 'sub-sect
IF cb$ = "PageParameters" OR cb$ = "Parameters" THEN cbo$ = "Parameters:" 'w/o Page suffix is deprecated (but kept for existing pages)
IF cb$ = "PageParameters" OR cb$ = "Parameters" THEN cbo$ = "Parameters:" 'w/o Page prefix is deprecated (but kept for existing pages)
IF cb$ = "PageDescription" THEN cbo$ = "Description:"
IF cb$ = "PageQBasic" THEN cbo$ = "QBasic/QuickBASIC" 'sub-sect
IF cb$ = "PageNotes" THEN cbo$ = "Notes" 'sub-sect
@ -699,6 +701,11 @@ SUB WikiParse (a$) 'Wiki page interpret
Help_AddTxt SPACE$((Help_ww - 52) \ 2) + "ÈÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍͼ", 8, 0
END IF
'Parameter template text will be italic
IF c$ = "|" AND cb$ = "Parameter" AND Help_LockParse <= 0 THEN 'keep as is in Code/Output blocks
Help_Italic = 1: col = Help_Col
END IF
'Small template text will be centered (maybe as block note)
IF LCASE$(cb$) = "small" AND Help_LockParse <= 0 THEN 'keep as is in Code/Output blocks
wla$ = wikiLookAhead$(a$, i + 1, "}}")