mirror of
https://github.com/QB64Official/qb64.git
synced 2024-08-22 11:25:08 +00:00
Show compilation progress (BASIC -> C++) in the status bar.
The only indication that the program was being compiled was the "..." on the status area. Now, if you hit F5 (or F11) and your program is still being compiled to C++, you will see a progress indicator on the bottom status line. Also: - Display "Start typing to search for text in this help page" upon invoking the help system (the search functionality is already built-in).
This commit is contained in:
parent
8749b28228
commit
546947d967
2 changed files with 44 additions and 17 deletions
|
@ -3,5 +3,5 @@ DIM SHARED BuildNum AS STRING
|
||||||
Version$ = "1.000"
|
Version$ = "1.000"
|
||||||
'BuildNum format is YYYYMMDD/id, where id is a ever-increasing
|
'BuildNum format is YYYYMMDD/id, where id is a ever-increasing
|
||||||
'integer. If you make a change, update the date and increase the id!
|
'integer. If you make a change, update the date and increase the id!
|
||||||
BuildNum$ = "20160507/14"
|
BuildNum$ = "20160524/15"
|
||||||
|
|
||||||
|
|
|
@ -91,11 +91,28 @@ IF ASC(idecommand$) = 3 THEN 'request next line (compiler->ide)
|
||||||
idecompiledline$ = idegetline(idecompiledline)
|
idecompiledline$ = idegetline(idecompiledline)
|
||||||
ide = 4
|
ide = 4
|
||||||
idereturn$ = idecompiledline$
|
idereturn$ = idecompiledline$
|
||||||
|
|
||||||
|
'Update compilation progress on the status bar
|
||||||
|
IF IdeSystem <> 3 AND ideautorun <> 0 THEN
|
||||||
|
status.progress$ = str2$(INT((idecompiledline * 100) / iden))
|
||||||
|
status.progress$ = STRING$(3 - LEN(status.progress$), 32) + status.progress$ + "%)"
|
||||||
|
IF prepass THEN
|
||||||
|
status.progress$ = "Step 1/2 (" + status.progress$
|
||||||
|
ELSE
|
||||||
|
status.progress$ = "Step 2/2 (" + status.progress$
|
||||||
|
END IF
|
||||||
|
IdeInfo = status.progress$
|
||||||
|
END IF
|
||||||
|
UpdateIdeInfo
|
||||||
|
|
||||||
EXIT FUNCTION
|
EXIT FUNCTION
|
||||||
END IF
|
END IF
|
||||||
IF iCHANGED THEN iCHECKLATER = 1
|
IF iCHANGED THEN iCHECKLATER = 1
|
||||||
END IF 'ideexit
|
END IF 'ideexit
|
||||||
END IF 'not on screen
|
END IF 'not on screen
|
||||||
|
ELSE
|
||||||
|
IF IdeSystem <> 3 THEN IdeInfo = ""
|
||||||
|
UpdateIdeInfo
|
||||||
END IF 'idecompiledline<iden
|
END IF 'idecompiledline<iden
|
||||||
END IF
|
END IF
|
||||||
|
|
||||||
|
@ -832,6 +849,7 @@ DO
|
||||||
IF idechangemade THEN
|
IF idechangemade THEN
|
||||||
COLOR 7, 1: LOCATE idewy - 3, 2: PRINT SPACE$(idewx - 2);: LOCATE idewy - 2, 2: PRINT SPACE$(idewx - 2);: LOCATE idewy - 1, 2: PRINT SPACE$(idewx - 2); 'clear status window
|
COLOR 7, 1: LOCATE idewy - 3, 2: PRINT SPACE$(idewx - 2);: LOCATE idewy - 2, 2: PRINT SPACE$(idewx - 2);: LOCATE idewy - 1, 2: PRINT SPACE$(idewx - 2); 'clear status window
|
||||||
|
|
||||||
|
IF LEFT$(IdeInfo, 5) = "Step " THEN IdeInfo = ""
|
||||||
|
|
||||||
LOCATE idewy - 3, 2: PRINT "..."; 'assume new compilation will begin
|
LOCATE idewy - 3, 2: PRINT "..."; 'assume new compilation will begin
|
||||||
END IF
|
END IF
|
||||||
|
@ -890,13 +908,22 @@ DO
|
||||||
END IF
|
END IF
|
||||||
NEXT
|
NEXT
|
||||||
'Help_Search_Str
|
'Help_Search_Str
|
||||||
a$ = ""
|
IF IdeSystem = 3 THEN
|
||||||
IF LEN(Help_Search_Str) THEN
|
a$ = ""
|
||||||
a$ = Help_Search_Str
|
IF LEN(Help_Search_Str) THEN
|
||||||
IF LEN(a$) > 20 THEN a$ = string$(3, 250) + RIGHT$(a$, 17)
|
a$ = Help_Search_Str
|
||||||
a$ = "[" + a$ + "](DELETE=next)"
|
IF LEN(a$) > 20 THEN a$ = string$(3, 250) + RIGHT$(a$, 17)
|
||||||
|
a$ = "[" + a$ + "](DELETE=next)"
|
||||||
|
IdeInfo = a$
|
||||||
|
ELSE
|
||||||
|
IdeInfo = "Start typing to search for text in this help page"
|
||||||
|
END IF
|
||||||
|
ELSE
|
||||||
|
IdeInfo = ""
|
||||||
END IF
|
END IF
|
||||||
IdeInfo$ = a$
|
UpdateIdeInfo
|
||||||
|
ELSE
|
||||||
|
Help_Search_Str = ""
|
||||||
END IF
|
END IF
|
||||||
|
|
||||||
IF IdeSystem = 2 THEN 'override cursor position
|
IF IdeSystem = 2 THEN 'override cursor position
|
||||||
|
@ -920,16 +947,6 @@ DO
|
||||||
SCREEN , , 3, 0
|
SCREEN , , 3, 0
|
||||||
END IF
|
END IF
|
||||||
|
|
||||||
|
|
||||||
IF IdeSystem <> 3 THEN IdeInfo$ = ""
|
|
||||||
|
|
||||||
'show info message (if any)
|
|
||||||
a$ = IdeInfo$
|
|
||||||
IF LEN(a$) > 60 THEN a$ = LEFT$(a$, 57) + string$(3, 250)
|
|
||||||
IF LEN(a$) < 60 THEN a$ = a$ + SPACE$(60 - LEN(a$))
|
|
||||||
COLOR 0, 3: LOCATE idewy + idesubwindow, 2
|
|
||||||
PRINT a$;
|
|
||||||
|
|
||||||
LOCATE , , 1
|
LOCATE , , 1
|
||||||
|
|
||||||
|
|
||||||
|
@ -12611,5 +12628,15 @@ SUB AddQuickNavHistory(LineNumber&)
|
||||||
QuickNavHistory(QuickNavTotal) = LineNumber&
|
QuickNavHistory(QuickNavTotal) = LineNumber&
|
||||||
END SUB
|
END SUB
|
||||||
|
|
||||||
|
SUB UpdateIdeInfo
|
||||||
|
'show info message (if any)
|
||||||
|
a$ = IdeInfo
|
||||||
|
IF LEN(a$) > 60 THEN a$ = LEFT$(a$, 57) + string$(3, 250)
|
||||||
|
IF LEN(a$) < 60 THEN a$ = a$ + SPACE$(60 - LEN(a$))
|
||||||
|
COLOR 0, 3: LOCATE idewy + idesubwindow, 2
|
||||||
|
PRINT a$;
|
||||||
|
PCOPY 3, 0
|
||||||
|
END SUB
|
||||||
|
|
||||||
'$INCLUDE:'wiki\wiki_methods.bas'
|
'$INCLUDE:'wiki\wiki_methods.bas'
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue