Fontos klub információ
Important club information
Welcome, Guest. Please login or register.


Author Topic: Questions about QUIGS programming. (Read 541 times)

Online gflorez

  • EP addict
  • *
  • Posts: 2771
  • Country: es
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 73.0 Firefox 73.0
    • View Profile
Questions about QUIGS programming.
« on: 2020.March.05. 21:15:10 »
Tutus, can you put here your .qpf program? Maybe I can fix it.

 

Offline Tutus

  • EP user
  • *
  • Posts: 459
  • Country: hu
  • OS:
  • Windows NT 10.0 Windows NT 10.0
  • Browser:
  • Firefox 73.0 Firefox 73.0
    • View Profile
    • Enterpress News
Re: Questions about QUIGS programming.
« Reply #1 on: 2020.March.06. 11:27:29 »
Thank you for this topic, Gustavo :)

I did the following:
- I rewrote the header
- I loaded a small image into the sheet with a .bmp extension
- I opened an image box on the form and referred to the image in the sheet
- I signed a text under the picture
After Compile, the .exe launched in SymbOS: the cursor is bounced, nothing else is displayed.



Online gflorez

  • EP addict
  • *
  • Posts: 2771
  • Country: es
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 73.0 Firefox 73.0
    • View Profile
Re: Questions about QUIGS programming.
« Reply #2 on: 2020.March.06. 18:44:53 »
It has not been easy....

Code: [Select]
// Quigs 1.01 Application for Symbos
// Name:
// Coder:
// Date / Version:

// Declare variables
Var Enter:Sheet   // a curious type of variable to store  graphics

// End declares

Function Main:Void()
// Main loop

EndF

Function Image1.Event:Void()

//Lets load the Sheet according to No. of colours
If Screen.Colour = 2 Then
//Its a 2 colour image so xxx.qs1
Enter.Load(App.Path+"Sheet1.qs1")   // these two sets of graphics are created automatically
Else
//Its a 4 colour image so xxx.qs2
Enter.Load(App.Path+"Sheet1.qs2")   // and have to go with the application.
EndIf

Ctrl.Image.Tile.Set Image1, Enter,0   // this command loads the file on the Image1 control
Ctrl.Refresh Image1       // this command rewrites the event.


EndF

Function Form1.Close.Event:Void()
Enter.Free   //releases memory at exit
EndF
Function Form1.Open.Event:Void()
Image1.Event       // this is necessary to launch the Image1 event just at opening the program.


Also, if you want to show a text, the space has to be bigger than the No. of characters:

« Last Edit: 2020.March.06. 18:52:38 by gflorez »

Offline Tutus

  • EP user
  • *
  • Posts: 459
  • Country: hu
  • OS:
  • Mac OS X 10.15 Mac OS X 10.15
  • Browser:
  • Firefox 73.0 Firefox 73.0
    • View Profile
    • Enterpress News
Re: Questions about QUIGS programming.
« Reply #3 on: 2020.March.10. 20:50:51 »
Thank You! :)



It's really not easy. I'll study the code :D