BBC BASIC for Windows
« MULTIWIN libary updated »

Welcome Guest. Please Login or Register.
Apr 5th, 2018, 9:57pm



ATTENTION MEMBERS: Conforums will be closing it doors and discontinuing its service on April 15, 2018.
Ad-Free has been deactivated. Outstanding Ad-Free credits will be reimbursed to respective payment methods.

If you require a dump of the post on your message board, please come to the support board and request it.


Thank you Conforums members.

BBC BASIC for Windows Resources
Online BBC BASIC for Windows documentation
BBC BASIC for Windows Beginners' Tutorial
BBC BASIC Home Page
BBC BASIC on Rosetta Code
BBC BASIC discussion group
BBC BASIC for Windows Programmers' Reference

« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: MULTIWIN libary updated  (Read 768 times)
rtr
Guest
xx MULTIWIN libary updated
« Thread started on: Aug 4th, 2014, 10:50am »

I have updated the MULTIWIN library to v2.1. It may be downloaded from here and should be copied into your LIB folder (administrative privileges will be required).

This version has added support for initialising 'graphicboxes' (custom BBC dialogue controls).

Richard.
User IP Logged

KenDown
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 181
xx Re: MULTIWIN libary updated
« Reply #1 on: Sep 29th, 2015, 09:37am »

I *presume* this is a reference to FN_initctrl, which takes three parameters. I can't find any reference to this function in the Help files.

I'm guessing that D% is the dialog box handle, I% is the icon number, but N% has me baffled. Anyway, where do you set the size of the icon?

Richard can be terribly cryptic at times.
User IP Logged

DDRM
Administrator
ImageImageImageImageImage


member is offline

Avatar




PM

Gender: Male
Posts: 321
xx Re: MULTIWIN libary updated
« Reply #2 on: Sep 29th, 2015, 11:40am »

Hi Ken,

It's explained on the wiki:

http://bb4w.wikispaces.comCreating+a+custom+graphics+control

FN_initctrl allows you to insert a BB4W window as a control in a dialogue box:

"The parameters passed to FN_initctrl are the dialogue box pointer (as returned from FN_newdialog), the ID number assigned to the control (as specified in the call to PROC_dlgctrl) and the window number (between 1 and the number specified in the call to PROC_multiwin)".

Best wishes,

D
User IP Logged

KenDown
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 181
xx Re: MULTIWIN libary updated
« Reply #3 on: Sep 29th, 2015, 6:22pm »

Ah, thanks.

I wonder if there is any practical limit on the number of windows one can have? I have 9 in the program I am currently writing and if I were to add in one or two in a dialog box that would bring it up to 11, and so on.
User IP Logged

sveinioslo
Developer

member is offline

Avatar




PM


Posts: 64
xx Re: MULTIWIN libary updated
« Reply #4 on: Sep 29th, 2015, 7:35pm »

Why don't you try this and find out for yourself ;D

Close with ALT-F4
Code:
      REM Close with ALT-F4

      INSTALL @lib$+"WINLIB5A"
      INSTALL @lib$+"MULTIWIN"

      SYS "GetSystemMetrics", 0 TO xscreen%
      SYS "GetSystemMetrics", 1 TO yscreen%

      Max%=1000
      PROC_multiwin(Max%)
      ON CLOSE PROCcleanup : QUIT

      FOR I%=1 TO Max%
        hw1% = FN_createwin(I%, "Window "+STR$I%, X%, Y%, 100, 100, 0, &96C00000, 0)
        X%+=30 : IF X% >=xscreen%-100 THEN X%=0 : Y%+=100
        IF Y%>yscreen%-100 THEN Max%=I% : EXIT FOR
      NEXT I%

      REPEAT
        FOR I%=1 TO Max%
          PROC_selectwin(I%)
          COLOUR RND(15)-1
          PRINT '"Hello world!";
        NEXT I%
        WAIT 20
      UNTIL FALSE

      DEF PROCcleanup
      PROC_selectwin(0)
      FOR I%=1 TO Max%
        PROC_closewin(I%)
      NEXT I%
      ENDPROC
 


Svein

User IP Logged

KenDown
Full Member
ImageImageImage


member is offline

Avatar




PM


Posts: 181
xx Re: MULTIWIN libary updated
« Reply #5 on: Sep 29th, 2015, 8:02pm »

He he! Very clever. I got up to 610 on my computer and presumably it could have gone further if there had been more room on the screen.

Still, if those windows were larger, things might have been a little different. I'm intrigued by the comment someone made about a window having a bitmap - and bitmaps take up memory.
User IP Logged

Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

| |

This forum powered for FREE by Conforums ©
Terms of Service | Privacy Policy | Conforums Support | Parental Controls