cobc -x -o my_program init.cob $(pkg-config --cflags --libs ncurses) -static $> ./NcursesInlineCExample.exe
this above... or this below... does not produce a grid
$> cobc -x -o NcursesInlineCExample init.cob -lncurses -static $> ./NcursesInlineCExample.exe
it just kind of waits out there hanging around not doing anything...
IDENTIFICATION DIVISION. PROGRAM-ID. NcursesInlineCExample.
ENVIRONMENT DIVISION. CONFIGURATION SECTION. DATA DIVISION. WORKING-STORAGE SECTION. 01 WS-RETURN-CODE PIC S9(9) COMP. LINKAGE SECTION. 01 C-RETURN-CODE PIC S9(9) COMP. PROCEDURE DIVISION. MAIN-PROCEDURE. PERFORM C-INITIALIZE-NCURSES. IF WS-RETURN-CODE < 0 DISPLAY "Failed to initialize ncurses." ELSE PERFORM C-SHOW-GRID PERFORM C-WAIT-FOR-KEY END-IF. PERFORM C-FINALIZE-NCURSES. STOP RUN. C-INITIALIZE-NCURSES. CALL 'initscr' USING C-RETURN-CODE. C-SHOW-GRID. CALL 'mvprintw' USING 1 1 "+---+---+". CALL 'mvprintw' USING 2 1 "| 1 | 2 |". CALL 'mvprintw' USING 3 1 "+---+---+". CALL 'mvprintw' USING 4 1 "| 3 | 4 |". CALL 'mvprintw' USING 5 1 "+---+---+". CALL 'refresh'. C-WAIT-FOR-KEY. CALL 'getch'. C-FINALIZE-NCURSES. CALL 'endwin'.
its the call to mvprintw that isnt executing right away thanks
jim
Sent with Proton Mail secure email.
Anonymous
You seem to have CSS turned off. Please don't fill out this field.
In my opinion calling curses functions directly from gnucobol is not supported or recommended.
per the pdcursesmod documentation which I'm most familiar with, a "refresh" call is needed to update the physical terminal screen.
Chuck Haatvedt
Hi Chuck-
I will try to do some kind of refresh call. Thank you so much.
I am going to ride it out with cygwin. I like it a lot better than mingw and dont want both environments on my PC taking up space.
Not only that I am using cygwin for other things a bit in the recent past.
thanks for the assistance!
On Saturday, October 19th, 2024 at 6:07 PM, Chuck H. chaat@users.sourceforge.net wrote:
In my opinion calling curses functions directly from gnucobol is not supported or recommended. per the pdcursesmod documentation which I'm most familiar with, a "refresh" call is needed to update the physical terminal screen. Chuck Haatvedt straight c cobol example grid thanks Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/ To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/
straight c cobol example grid thanks
Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/
To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/
Chuck,
ummhh i did a refresh 2 different ways.
I am looking at trying to have a way to draw a grid layout on a cobol screen without typing everything by hand.
Chatgpt wants to use calls to ncurses.
I am stuck, any idea?
thanks
On Saturday, October 19th, 2024 at 6:23 PM, J McNamara masticon@users.sourceforge.net wrote:
Hi Chuck- I will try to do some kind of refresh call. Thank you so much. I am going to ride it out with cygwin. I like it a lot better than mingw and dont want both environments on my PC taking up space. Not only that I am using cygwin for other things a bit in the recent past. thanks for the assistance! jim Sent with Proton Mail secure email. On Saturday, October 19th, 2024 at 6:07 PM, Chuck H. chaat@users.sourceforge.net wrote: In my opinion calling curses functions directly from gnucobol is not supported or recommended. per the pdcursesmod documentation which I'm most familiar with, a "refresh" call is needed to update the physical terminal screen. Chuck Haatvedt straight c cobol example grid thanks Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/ To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/ straight c cobol example grid thanks Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/ To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/
Don't use ChatGPT for COBOL as it is one of the parts where it performs worst...
For drawing checkout the NEWS entry for the control (?) attribute added, which allows you to use curses drawing without direct calls.
You'd also find the closed-implemented feature request on this on SF under "tickets".
Am 20. Oktober 2024 00:37:37 MESZ schrieb J McNamara masticon@users.sourceforge.net:
Chuck, ummhh i did a refresh 2 different ways. I am looking at trying to have a way to draw a grid layout on a cobol screen without typing everything by hand. Chatgpt wants to use calls to ncurses. I am stuck, any idea? thanks Sent with Proton Mail secure email. On Saturday, October 19th, 2024 at 6:23 PM, J McNamara masticon@users.sourceforge.net wrote: Hi Chuck- I will try to do some kind of refresh call. Thank you so much. I am going to ride it out with cygwin. I like it a lot better than mingw and dont want both environments on my PC taking up space. Not only that I am using cygwin for other things a bit in the recent past. thanks for the assistance! jim Sent with Proton Mail secure email. On Saturday, October 19th, 2024 at 6:07 PM, Chuck H. chaat@users.sourceforge.net wrote: In my opinion calling curses functions directly from gnucobol is not supported or recommended. per the pdcursesmod documentation which I'm most familiar with, a "refresh" call is needed to update the physical terminal screen. Chuck Haatvedt straight c cobol example grid thanks Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/ To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/ straight c cobol example grid thanks Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/ To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/ straight c cobol example grid thanks Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/ To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/
Hi,
I don't know exactly what you want, but if you use curses, then it is better to use screen-sections. If you want paging, listing functionality with a "grid" you can check the programs here: https://sourceforge.net/p/gnucobol/contrib/HEAD/tree/trunk/samples/DBsample/
See example7 and the screenshots.
László
okay this is a very cool resource.
I took a break for a little while.
I am teaching myself to edit video.
thanks and when i get back to it in a little while I will definitely check out the example with screenshots.
On Saturday, October 26th, 2024 at 5:11 PM, László Erdős laszloerdos@users.sourceforge.net wrote:
Hi, I don't know exactly what you want, but if you use curses, then it is better to use screen-sections. If you want paging, listing functionality with a "grid" you can check the programs here: https://sourceforge.net/p/gnucobol/contrib/HEAD/tree/trunk/samples/DBsample/ See example7 and the screenshots. László straight c cobol example grid thanks Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/gnucobol/discussion/help/ To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/
cobc -x -o my_program init.cob $(pkg-config --cflags --libs ncurses) -static
$> ./NcursesInlineCExample.exe
this above... or this below... does not produce a grid
$> cobc -x -o NcursesInlineCExample init.cob -lncurses -static
$> ./NcursesInlineCExample.exe
it just kind of waits out there hanging around not doing anything...
IDENTIFICATION DIVISION.
PROGRAM-ID. NcursesInlineCExample.
its the call to mvprintw that isnt executing right away thanks
jim
Sent with Proton Mail secure email.
In my opinion calling curses functions directly from gnucobol is not supported or recommended.
per the pdcursesmod documentation which I'm most familiar with, a "refresh" call is needed to update the physical terminal screen.
Hi Chuck-
I will try to do some kind of refresh call. Thank you so much.
I am going to ride it out with cygwin. I like it a lot better than mingw and dont want both environments on my PC taking up space.
Not only that I am using cygwin for other things a bit in the recent past.
thanks for the assistance!
jim
Sent with Proton Mail secure email.
On Saturday, October 19th, 2024 at 6:07 PM, Chuck H. chaat@users.sourceforge.net wrote:
Chuck,
ummhh i did a refresh 2 different ways.
I am looking at trying to have a way to draw a grid layout on a cobol screen without typing
everything by hand.
Chatgpt wants to use calls to ncurses.
I am stuck, any idea?
thanks
Sent with Proton Mail secure email.
On Saturday, October 19th, 2024 at 6:23 PM, J McNamara masticon@users.sourceforge.net wrote:
Don't use ChatGPT for COBOL as it is one of the parts where it performs worst...
For drawing checkout the NEWS entry for the control (?) attribute added, which allows you to use curses drawing without direct calls.
You'd also find the closed-implemented feature request on this on SF under "tickets".
Am 20. Oktober 2024 00:37:37 MESZ schrieb J McNamara masticon@users.sourceforge.net:
Hi,
I don't know exactly what you want, but if you use curses, then it is better to use screen-sections. If you want paging, listing functionality with a "grid" you can check the programs here:
https://sourceforge.net/p/gnucobol/contrib/HEAD/tree/trunk/samples/DBsample/
See example7 and the screenshots.
László
okay this is a very cool resource.
I took a break for a little while.
I am teaching myself to edit video.
thanks and when i get back to it in a little while I will definitely check out the example with screenshots.
thanks
Sent with Proton Mail secure email.
On Saturday, October 26th, 2024 at 5:11 PM, László Erdős laszloerdos@users.sourceforge.net wrote: