1
1
Fork 0
mirror of https://github.com/FellippeHeitor/InForm.git synced 2024-05-12 06:50:12 +00:00

Update README.md. Remove updater icon.

This commit is contained in:
Samuel Gomes 2023-05-09 02:48:11 +05:30
parent a3ba9a6feb
commit 8a7f850c93
10 changed files with 839 additions and 877 deletions

View file

@ -1,10 +1,7 @@
'Starting with v1.0, __UI_VersionNumber is actually the current build.
$IF INFORMVERSION_BAS = UNDEFINED THEN
$LET INFORMVERSION_BAS = TRUE
CONST __UI_Version = "v1.5"
CONST __UI_VersionNumber = 0
CONST __UI_VersionIsBeta = 1
CONST __UI_CopyrightSpan = "2016-2023"
$END IF
CONST __UI_Version = "v1.5"
CONST __UI_VersionNumber = 0
CONST __UI_VersionIsBeta = 1
CONST __UI_CopyrightSpan = "2016-2023"

View file

@ -2659,7 +2659,7 @@ SUB __UI_OnLoad
'Load splash image:
DIM tempIcon AS LONG
tempIcon = _LOADIMAGE("resources/Application-icon-128.png", 32)
tempIcon = _LOADIMAGE("InForm/resources/Application-icon-128.png", 32)
GOSUB ShowMessage

View file

@ -1,67 +1,64 @@
$IF DOWNLOAD_BAS = UNDEFINED THEN
$LET DOWNLOAD_BAS = TRUE
FUNCTION Download$ (url$, file$, timelimit) STATIC
'as seen on http://www.qb64.org/wiki/Downloading_Files
'adapted for use with InForm
FUNCTION Download$ (url$, file$, timelimit) STATIC
'as seen on http://www.qb64.org/wiki/Downloading_Files
'adapted for use with InForm
DIM theClient AS LONG, l AS LONG
DIM prevUrl$, prevUrl2$, url2$, x AS LONG
DIM e$, url3$, x$, t!, a2$, a$, i AS LONG
DIM i2 AS LONG, i3 AS LONG, d$, fh AS LONG
DIM theClient AS LONG, l AS LONG
DIM prevUrl$, prevUrl2$, url2$, x AS LONG
DIM e$, url3$, x$, t!, a2$, a$, i AS LONG
DIM i2 AS LONG, i3 AS LONG, d$, fh AS LONG
IF url$ <> prevUrl$ OR url$ = "" THEN
prevUrl$ = url$
IF url$ = "" THEN
IF theClient THEN CLOSE theClient: theClient = 0
EXIT FUNCTION
END IF
url2$ = url$
x = INSTR(url2$, "/")
IF x THEN url2$ = LEFT$(url$, x - 1)
IF url2$ <> prevUrl2$ THEN
prevUrl2$ = url2$
IF theClient THEN CLOSE theClient: theClient = 0
theClient = _OPENCLIENT("TCP/IP:80:" + url2$)
IF theClient = 0 THEN Download = MKI$(2): prevUrl$ = "": EXIT FUNCTION
END IF
e$ = CHR$(13) + CHR$(10) ' end of line characters
url3$ = RIGHT$(url$, LEN(url$) - x + 1)
x$ = "GET " + url3$ + " HTTP/1.1" + e$
x$ = x$ + "Host: " + url2$ + e$ + e$
PUT #theClient, , x$
t! = TIMER ' start time
IF url$ <> prevUrl$ OR url$ = "" THEN
prevUrl$ = url$
IF url$ = "" THEN
IF theClient THEN CLOSE theClient: theClient = 0
EXIT FUNCTION
END IF
url2$ = url$
x = INSTR(url2$, "/")
IF x THEN url2$ = LEFT$(url$, x - 1)
IF url2$ <> prevUrl2$ THEN
prevUrl2$ = url2$
IF theClient THEN CLOSE theClient: theClient = 0
theClient = _OPENCLIENT("TCP/IP:80:" + url2$)
IF theClient = 0 THEN Download = MKI$(2): prevUrl$ = "": EXIT FUNCTION
END IF
e$ = CHR$(13) + CHR$(10) ' end of line characters
url3$ = RIGHT$(url$, LEN(url$) - x + 1)
x$ = "GET " + url3$ + " HTTP/1.1" + e$
x$ = x$ + "Host: " + url2$ + e$ + e$
PUT #theClient, , x$
t! = TIMER ' start time
END IF
GET #theClient, , a2$
a$ = a$ + a2$
i = INSTR(a$, "Content-Length:")
IF i THEN
i2 = INSTR(i, a$, e$)
IF i2 THEN
l = VAL(MID$(a$, i + 15, i2 - i - 14))
i3 = INSTR(i2, a$, e$ + e$)
IF i3 THEN
i3 = i3 + 4 'move i3 to start of data
IF (LEN(a$) - i3 + 1) = l THEN
d$ = MID$(a$, i3, l)
fh = FREEFILE
OPEN file$ FOR OUTPUT AS #fh: CLOSE #fh 'Warning! Clears data from existing file
OPEN file$ FOR BINARY AS #fh
PUT #fh, , d$
CLOSE #fh
Download = MKI$(1) + MKL$(l) 'indicates download was successful
prevUrl$ = ""
prevUrl2$ = ""
a$ = ""
CLOSE theClient
theClient = 0
EXIT FUNCTION
END IF ' availabledata = l
END IF ' i3
END IF ' i2
END IF ' i
IF TIMER > t! + timelimit THEN CLOSE theClient: theClient = 0: Download = MKI$(3): prevUrl$ = "": EXIT FUNCTION
Download = MKI$(0) 'still working
END FUNCTION
$END IF
GET #theClient, , a2$
a$ = a$ + a2$
i = INSTR(a$, "Content-Length:")
IF i THEN
i2 = INSTR(i, a$, e$)
IF i2 THEN
l = VAL(MID$(a$, i + 15, i2 - i - 14))
i3 = INSTR(i2, a$, e$ + e$)
IF i3 THEN
i3 = i3 + 4 'move i3 to start of data
IF (LEN(a$) - i3 + 1) = l THEN
d$ = MID$(a$, i3, l)
fh = FREEFILE
OPEN file$ FOR OUTPUT AS #fh: CLOSE #fh 'Warning! Clears data from existing file
OPEN file$ FOR BINARY AS #fh
PUT #fh, , d$
CLOSE #fh
Download = MKI$(1) + MKL$(l) 'indicates download was successful
prevUrl$ = ""
prevUrl2$ = ""
a$ = ""
CLOSE theClient
theClient = 0
EXIT FUNCTION
END IF ' availabledata = l
END IF ' i3
END IF ' i2
END IF ' i
IF TIMER > t! + timelimit THEN CLOSE theClient: theClient = 0: Download = MKI$(3): prevUrl$ = "": EXIT FUNCTION
Download = MKI$(0) 'still working
END FUNCTION

View file

@ -6,57 +6,53 @@
'#######################################################################################
'Adapted for use with InForm's PictureBox controls by @FellippeHeitor
$IF GIFPLAY_BI = UNDEFINED THEN
$LET GIFPLAY_BI = TRUE
TYPE GIFDATA
ID AS LONG
file AS INTEGER
sigver AS STRING * 6
width AS _UNSIGNED INTEGER
height AS _UNSIGNED INTEGER
bpp AS _UNSIGNED _BYTE
sortFlag AS _BYTE ' Unused
colorRes AS _UNSIGNED _BYTE
colorTableFlag AS _BYTE
bgColor AS _UNSIGNED _BYTE
aspect AS SINGLE ' Unused
numColors AS _UNSIGNED INTEGER
palette AS STRING * 768
firstFrame AS LONG
totalFrames AS LONG
IsPlaying AS _BYTE
Frame AS LONG
LoadedFrames AS LONG
GifLoadComplete AS _BYTE
LastFrameServed AS LONG
LastFrameUpdate AS SINGLE
LastFrameDelay AS SINGLE
HideOverlay AS _BYTE
END TYPE
TYPE GIFDATA
ID AS LONG
file AS INTEGER
sigver AS STRING * 6
width AS _UNSIGNED INTEGER
height AS _UNSIGNED INTEGER
bpp AS _UNSIGNED _BYTE
sortFlag AS _BYTE ' Unused
colorRes AS _UNSIGNED _BYTE
colorTableFlag AS _BYTE
bgColor AS _UNSIGNED _BYTE
aspect AS SINGLE ' Unused
numColors AS _UNSIGNED INTEGER
palette AS STRING * 768
firstFrame AS LONG
totalFrames AS LONG
IsPlaying AS _BYTE
Frame AS LONG
LoadedFrames AS LONG
GifLoadComplete AS _BYTE
LastFrameServed AS LONG
LastFrameUpdate AS SINGLE
LastFrameDelay AS SINGLE
HideOverlay AS _BYTE
END TYPE
TYPE FRAMEDATA
ID AS LONG
thisFrame AS LONG
addr AS LONG
left AS _UNSIGNED INTEGER
top AS _UNSIGNED INTEGER
width AS _UNSIGNED INTEGER
height AS _UNSIGNED INTEGER
localColorTableFlag AS _BYTE
interlacedFlag AS _BYTE
sortFlag AS _BYTE ' Unused
palBPP AS _UNSIGNED _BYTE
minimumCodeSize AS _UNSIGNED _BYTE
transparentFlag AS _BYTE 'GIF89a-specific (animation) values
userInput AS _BYTE ' Unused
disposalMethod AS _UNSIGNED _BYTE
delay AS SINGLE
transColor AS _UNSIGNED _BYTE
END TYPE
TYPE FRAMEDATA
ID AS LONG
thisFrame AS LONG
addr AS LONG
left AS _UNSIGNED INTEGER
top AS _UNSIGNED INTEGER
width AS _UNSIGNED INTEGER
height AS _UNSIGNED INTEGER
localColorTableFlag AS _BYTE
interlacedFlag AS _BYTE
sortFlag AS _BYTE ' Unused
palBPP AS _UNSIGNED _BYTE
minimumCodeSize AS _UNSIGNED _BYTE
transparentFlag AS _BYTE 'GIF89a-specific (animation) values
userInput AS _BYTE ' Unused
disposalMethod AS _UNSIGNED _BYTE
delay AS SINGLE
transColor AS _UNSIGNED _BYTE
END TYPE
REDIM SHARED GifData(0) AS GIFDATA
REDIM SHARED GifFrameData(0) AS FRAMEDATA
DIM SHARED TotalGIFLoaded AS LONG, TotalGIFFrames AS LONG
$END IF
REDIM SHARED GifData(0) AS GIFDATA
REDIM SHARED GifFrameData(0) AS FRAMEDATA
DIM SHARED TotalGIFLoaded AS LONG, TotalGIFFrames AS LONG

View file

@ -6,31 +6,27 @@
'#######################################################################################
'Adapted for use with InForm's PictureBox controls by @FellippeHeitor
'$Include:'gifplay.bi'
SUB UpdateGif (ID AS LONG)
DIM i AS LONG, newFrame AS LONG
STATIC GifOverlay AS LONG
$IF GIFPLAY_BM = UNDEFINED THEN
$LET GIFPLAY_BM = TRUE
SUB UpdateGif (ID AS LONG)
DIM i AS LONG, newFrame AS LONG
STATIC GifOverlay AS LONG
i = GetGifIndex(ID)
i = GetGifIndex(ID)
IF i = 0 THEN EXIT SUB
IF i = 0 THEN EXIT SUB
IF GifOverlay = 0 THEN
GifOverlay = LoadOverlayImage&
END IF
IF GifOverlay = 0 THEN
GifOverlay = LoadOverlayImage&
END IF
IF GifData(i).IsPlaying OR GifData(i).LastFrameServed = 0 THEN
IF GifData(i).LastFrameUpdate > 0 AND TIMER - GifData(i).LastFrameUpdate < GifData(i).LastFrameDelay THEN
'Wait for the GIF's frame delay
ELSE
GifData(i).Frame = GifData(i).Frame + 1
GifData(i).LastFrameServed = GifData(i).Frame
GifData(i).LastFrameUpdate = TIMER
END IF
IF GifData(i).IsPlaying OR GifData(i).LastFrameServed = 0 THEN
IF GifData(i).LastFrameUpdate > 0 AND TIMER - GifData(i).LastFrameUpdate < GifData(i).LastFrameDelay THEN
'Wait for the GIF's frame delay
ELSE
GifData(i).Frame = GifData(i).Frame + 1
GifData(i).LastFrameServed = GifData(i).Frame
GifData(i).LastFrameUpdate = TIMER
END IF
END IF
BeginDraw ID
newFrame = GetGifFrame&(i)
@ -883,5 +879,4 @@ FUNCTION gifUnpack$ (PackedData$)
gifUnpack$ = btemp$
END FUNCTION
'############################################################################################
$endif

View file

@ -4,21 +4,18 @@
'This file isn't required to be at the top of your programs,
'unless you intend to use OPTION _EXPLICIT
$IF INI_BI = UNDEFINED THEN
$LET INI_BI = TRUE
'Global variables declaration
DIM currentIniFileName$
DIM currentIniFileLOF AS _UNSIGNED LONG
DIM IniWholeFile$
DIM IniSectionData$
DIM IniPosition AS _UNSIGNED LONG
DIM IniNewFile$
DIM IniLastSection$
DIM IniLastKey$
DIM IniLF$
DIM IniDisableAutoCommit
DIM IniCODE
DIM IniAllowBasicComments
DIM IniForceReload
$END IF
'Global variables declaration
DIM currentIniFileName$
DIM currentIniFileLOF AS _UNSIGNED LONG
DIM IniWholeFile$
DIM IniSectionData$
DIM IniPosition AS _UNSIGNED LONG
DIM IniNewFile$
DIM IniLastSection$
DIM IniLastKey$
DIM IniLF$
DIM IniDisableAutoCommit
DIM IniCODE
DIM IniAllowBasicComments
DIM IniForceReload

File diff suppressed because it is too large Load diff

View file

@ -4,10 +4,3 @@ Artist: Custom Icon Design (Available for custom work)
Iconset: Flatastic 11 Icons (60 icons)
License: Free for non-commercial use.
Commercial usage: Buy commercial license here: http://www.customicondesign.com/free-icons/flatastic-icon-set/flatastic-part-11
http://www.iconarchive.com/show/oxygen-icons-by-oxygen-icons.org/Apps-system-software-update-icon.html
"Apps system software update Icon"
Artist: Oxygen Team
Iconset: Oxygen Icons (883 icons)
License: GNU Lesser General Public License
Commercial usage: Allowed

Binary file not shown.

Before

Width:  |  Height:  |  Size: 211 KiB

View file

@ -2,7 +2,7 @@
![InForm logo](InForm/resources/Application-icon-128.png)
A GUI engine and WYSIWYG interface designer for QB64 and QB64-PE
A GUI engine and WYSIWYG interface designer for QB64-PE
Wiki: <https://github.com/a740g/InForm/wiki>
@ -37,11 +37,3 @@ the actual program you will add your code to.
* *BeforeUpdateDisplay*, triggered everytime the form is about to be repainted.
* *BeforeUnload*, triggered when the user tries to close the program, either via clicking the window's X button, right click in the task bar -> Close or with Alt+F4 (Windows only).
* *FormResized*, triggered when a form with the CanResize property is resized at runtime.
## Developer Goals
* Decouple QB64-PE internal features from the library (e.g. falcon.h)
* Ensure library continues to work even if QB64-PE font library changes 😉
* Make the library standalone and work from any directory
* Remove all gimmicky features like the defunct auto-update & installer
* Ensure the library does not write anything to disk and runs completely from memory