From b1c9733420e2ce6d6435bac419d3c1e8a9c9f7ba Mon Sep 17 00:00:00 2001 From: Roland Heyder Date: Sun, 12 Feb 2023 19:41:25 +0100 Subject: [PATCH] Removes old code - unused (commented) code - no longer needed HTML tag handling (eliminated from Wiki pages) - #toc/#top link filters removed (those links are supported now) --- source/ide/ide_methods.bas | 25 --------------------- source/ide/wiki/wiki_methods.bas | 38 ++++---------------------------- 2 files changed, 4 insertions(+), 59 deletions(-) diff --git a/source/ide/ide_methods.bas b/source/ide/ide_methods.bas index 837a66c04..a0bf6ba35 100644 --- a/source/ide/ide_methods.bas +++ b/source/ide/ide_methods.bas @@ -17703,19 +17703,9 @@ SUB Help_ShowText REDIM Help_LineLen(Help_wh) - COLOR 7, 0 - - 'CLS - 'FOR y = Help_wy1 - 1 TO Help_wy2 + 1 - ' FOR x = Help_wx1 - 1 TO Help_wx2 + 1 - ' LOCATE y, x: PRINT chr$(219); - ' NEXT - 'NEXT - sy = Help_wy1 FOR y = Help_sy TO Help_sy + Help_wh - 1 IF y <= help_h THEN - 'PRINT CVL(MID$(Help_Line$, (y - 1) * 4 + 1, 4)), LEN(Help_Txt$) l = CVL(MID$(Help_Line$, (y - 1) * 4 + 1, 4)) x = l x3 = 1 @@ -17779,21 +17769,6 @@ SUB Help_ShowText sy = sy + 1 NEXT - 'LOCATE Help_cy - Help_sy + Help_wy1, Help_cx - Help_sx + Help_wx1 - 'COLOR 15, 4 - 'PRINT CHR$(SCREEN(CSRLIN, POS(0))); - - 'c = 0 - 'DO - ' old_kcontrol = KCONTROL - ' GetInput - ' IF KB > 0 THEN c = 1 - ' IF mCLICK THEN c = 1 - ' IF mWHEEL THEN c = 1 - ' IF KCONTROL AND old_kcontrol = 0 THEN c = 0 - ' IF mB THEN c = 1 - 'LOOP UNTIL c - END SUB diff --git a/source/ide/wiki/wiki_methods.bas b/source/ide/wiki/wiki_methods.bas index f30184eab..6167b9f20 100644 --- a/source/ide/wiki/wiki_methods.bas +++ b/source/ide/wiki/wiki_methods.bas @@ -377,20 +377,13 @@ SUB WikiParse (a$) 'Wiki page interpret 'Direct HTML code is not handled in Code/Output blocks (hard lock), as all text 'could be part of the code example itself (just imagine a HTML parser/writer demo) IF Help_LockParse <= 0 THEN - s$ = "": IF c$(LEN(s$)) = s$ THEN Help_AddTxt "^", col, 0: i = i + LEN(s$) - 1: GOTO charDone - s$ = "": IF c$(LEN(s$)) = s$ THEN i = i + LEN(s$) - 1: GOTO charDone - s$ = "
" 'centered section IF c$(LEN(s$)) = s$ THEN i = i + LEN(s$) - 1 wla$ = wikiLookAhead$(a$, i + 1, "
") - IF INSTR(wla$, "#toc") > 0 OR INSTR(wla$, "#top") > 0 OR INSTR(wla$, "to Top") > 0 THEN - i = i + LEN(wla$) + 9 'ignore TOC/TOP links - ELSE - Help_Center = 1: Help_CIndent$ = wikiBuildCIndent$(wla$) - Help_AddTxt SPACE$(ASC(Help_CIndent$, 1)), col, 0 'center content - Help_CIndent$ = MID$(Help_CIndent$, 2) - END IF + Help_Center = 1: Help_CIndent$ = wikiBuildCIndent$(wla$) + Help_AddTxt SPACE$(ASC(Help_CIndent$, 1)), col, 0 'center content + Help_CIndent$ = MID$(Help_CIndent$, 2) GOTO charDone END IF s$ = "" @@ -406,9 +399,7 @@ SUB WikiParse (a$) 'Wiki page interpret FOR ii = i TO LEN(a$) - 1 IF MID$(a$, ii, 1) = ">" THEN wla$ = wikiLookAhead$(a$, ii + 1, "

") - IF INSTR(wla$, "#toc") > 0 OR INSTR(wla$, "#top") > 0 OR INSTR(wla$, "to Top") > 0 THEN - i = ii + LEN(wla$) + 4 'ignore TOC/TOP links - ELSEIF INSTR(MID$(a$, i, ii - i), "center") > 0 THEN + IF INSTR(MID$(a$, i, ii - i), "center") > 0 THEN Help_Center = 1: Help_CIndent$ = wikiBuildCIndent$(wla$) Help_AddTxt SPACE$(ASC(Help_CIndent$, 1)), col, 0 'center (if in style) Help_CIndent$ = MID$(Help_CIndent$, 2) @@ -426,28 +417,7 @@ SUB WikiParse (a$) 'Wiki page interpret Help_NewLine GOTO charDone END IF - s$ = "