PE Programming for dummies

Anything QL Software or Programming Related.
User avatar
pjw
QL Wafer Drive
Posts: 1286
Joined: Fri Jul 11, 2014 8:44 am
Location: Norway
Contact:

Re: PE Programming for dummies

Post by pjw »

Andrew wrote:<>
I have so much to learn :(
Its a hard slog, but you seem to be doing just fine :)


Per
dont be happy. worry
- ?
User avatar
pjw
QL Wafer Drive
Posts: 1286
Joined: Fri Jul 11, 2014 8:44 am
Location: Norway
Contact:

Re: PE Programming for dummies

Post by pjw »

desin wrote:Hello
here is my vertical resize demo
testet under QPC2, Smsqemulator, Q-emulator. sQLux all resolution QDOS and SMSQE
but it wont work on Mist(er)
any ideas ?
The BASIC version works in QPC2. But you shouldnt hard-wire file locations in your code. You could use HOME_DIR$, for example..

There are other issues.. But a good start!


Per
dont be happy. worry
- ?
User avatar
desin
Chuggy Microdrive
Posts: 50
Joined: Mon May 10, 2021 10:33 am

Re: PE Programming for dummies

Post by desin »

been there done that

Home_dir is SMSQE only (for the moment)

Markus


User avatar
tofro
Font of All Knowledge
Posts: 2685
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: PE Programming for dummies

Post by tofro »

desin wrote:been there done that

Home_dir is SMSQE only (for the moment)
Well, there actually is a loadable HOME thing for QDOS - The problem is, the home dir is not set by EX or EW from the Basic command line. It does, however, work to my knowledge, with QPAC2 Files and some other file managers.


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
Artificer
Brittle Membrane
Posts: 120
Joined: Fri Nov 24, 2017 8:43 am

Re: PE Programming for dummies

Post by Artificer »

Andrew wrote
My guess is that this is because PE oulines the first created channel, which is the main window and the filemenu is larger than the main window.
Yes. The menu extension has a minimum size that it will work with. I wrote that down somewhere but cannot find it now but a minimum size of on outlined window of 512x128 or thereabouts should work OK. The y size is more flexible than the x dimension.

Another way to set home directories is the Enviroment variables extension its on Dilwyn's site, no need for smsq/e for it to work and it can be used to set default directories for programs in the boot file and change them on the fly if needed.

As for getting a filemenu window when the main application window is small the quick answer is to close the application main window, outline a window of dimensions that will work with your display and the file menu extension, pop the file menu into that window channel, throw the window away and reopen the applications main window. No need for a separate job and job to job communication. I cannot tell you the code to do this in easymenu as I have only used the QPTR extensions. Bought them in the late 1990s and I am still learning how to get the most out of them.

Cheers


User avatar
Andrew
Aurora
Posts: 786
Joined: Tue Jul 17, 2018 9:10 pm

Re: PE Programming for dummies

Post by Andrew »

Artificer wrote:As for getting a filemenu window when the main application window is small the quick answer is to close the application main window, outline a window of dimensions that will work with your display and the file menu extension, pop the file menu into that window channel, throw the window away and reopen the applications main window. No need for a separate job and job to job communication. I cannot tell you the code to do this in easymenu as I have only used the QPTR extensions.
I will try this in my next program!
But for now I just increased the main window by 6 pixels, to accomodate the filemenu.
Artificer wrote:Bought them in the late 1990s and I am still learning how to get the most out of them.
That's ... encouraging :?


User avatar
pjw
QL Wafer Drive
Posts: 1286
Joined: Fri Jul 11, 2014 8:44 am
Location: Norway
Contact:

Re: PE Programming for dummies

Post by pjw »

Artificer wrote:<>
As for getting a filemenu window when the main application window is small the quick answer is to close the application main window, outline a window of dimensions that will work with your display and the file menu extension, pop the file menu into that window channel, throw the window away and reopen the applications main window. No need for a separate job and job to job communication. I cannot tell you the code to do this in easymenu as I have only used the QPTR extensions. Bought them in the late 1990s and I am still learning how to get the most out of them.
That sounds like good old MSDOS! The really smart thing about Qdos, a
multitasking system from the start, is that one can have many small
jobs doing different tasks rather than one monolithic one having to
implement everything including the kitchen sink.

Qmenu's FILE_SELECT$ was supposed to be the solution. The problem it
suffers from is that it takes up a lot of screen real estate, so a job
with just a tiny window needs to make an unnecessarily large one to
display it or, as you suggest, close its windows, open a new one,
display the file selector, close that and reopen its own windows
again. Seems a bit clunky to me - especially since its unnecessary.

Inter-job communication isnt great for Qdos, apart from filters, but
it isnt that difficult either. Shared memory or pipes are some
solutions. SMSQ/E has others too, like History, named pipes and a few
others. And yes, Environmental Variables are another possibility, as
long as the list doesnt get too long and cluttered.


Per
dont be happy. worry
- ?
User avatar
Andrew
Aurora
Posts: 786
Joined: Tue Jul 17, 2018 9:10 pm

Re: PE Programming for dummies

Post by Andrew »

Charmap - The Final version
now everything works!
Attachments
charmap.zip
(116.65 KiB) Downloaded 121 times


User avatar
Artificer
Brittle Membrane
Posts: 120
Joined: Fri Nov 24, 2017 8:43 am

Re: PE Programming for dummies

Post by Artificer »

Andrew wrote
Charmap - The Final version
now everything works!
Yes it does. Have run it on my Q68. Great I have been thinking or writing something similar myself but there is no need now.

Cheers
CHARMAP.JPG


Tinyfpga
Gold Card
Posts: 252
Joined: Thu Sep 27, 2018 1:59 am

Re: PE Programming for dummies

Post by Tinyfpga »

Artificier posted:- Have run it on my Q68
Attractive setup. I assume your screen shot is not of your Q68. Is it SMSQ/E on a PC or something else? Would you be willing to post your BOOT file or better still a win_ file of your setup?


Post Reply