1. Win32 controls
- Posted by stab master <stabmaster_ at HOTMAIL.COM> Oct 25, 1999
- 634 views
My question isn't very Euphoria-specific (actually it's kinda C-oriented), but I figured some of you might be able to help anyway. The problem is as follows: How do I place controls (push-/radiobuttons, checkboxes, groupboxes etc.) on an applications' main window (NOT on a dialog window) ? Are main-window controls possible to create in the resource file or do I have to create them at run-time ? Some short sample code would be nice... ______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com
2. Re: Win32 controls
- Posted by Bernie Ryan <bwryan at PCOM.NET> Oct 25, 1999
- 585 views
On Mon, 25 Oct 1999 03:21:15 PDT, stab master <stabmaster_ at HOTMAIL.COM> wrote: >My question isn't very Euphoria-specific (actually it's kinda C-oriented), >but I figured some of you might be able to help anyway. >The problem is as follows: How do I place controls (push-/radiobuttons, >checkboxes, groupboxes etc.) on an applications' main window (NOT on a >dialog window) ? >Are main-window controls possible to create in the resource file or do I >have to create them at run-time ? >Some short sample code would be nice... > Are you using "C" or Euphoria to do the program ? What do you mean by "main-window controls possible to create in the resource file" ? If you are using Euphoria download my W32API20.ZIP file from the Euphoria site It will show you how to use Euphoria to do "C" windows programming be sure you read all the documents and comments. In demo 3 there is an example of using owner-draw buttons. Controls are actually child windows of the parent window. If you set a contol's parent to the main window it will appear on that window. Bernie
3. Re: Win32 controls
- Posted by stab master <stabmaster_ at HOTMAIL.COM> Oct 26, 1999
- 579 views
>Are you using "C" or Euphoria to do the program ? I am using C. Could as well be using assembly though, it's basically the same. >What do you mean by "main-window controls possible to create in the > resource file" ? This is a simple example of a (non-modal) dialog created in a resource file: Crappy_dialog DIALOG DISCARDABLE 10, 10, 140, 150 STYLE WS_POPUP | WS_SYSMENU | WS_CAPTION | DS_MODALFRAME CAPTION "Crappy dialog" FONT 8, "MS Sans Serif" { CTEXT "Push the button", 999, 18, 10, 80, 12 PUSHBUTTON "&Push me!", IDCANCEL, 18, 25, 75, 15 } I was wondering if it's possible to create controls as in the above example but "outside" of a dialog-block, so that the controls would end up in the application's main window instead of a dialog window. I hope my explanations are understandable. ______________________________________________________ Get Your Private, Free Email at http://www.hotmail.com
4. Re: Win32 controls
- Posted by Bernie Ryan <bwryan at PCOM.NET> Oct 26, 1999
- 620 views
---------------------------< cut >-------------------------------------- include win32lib.ew constant -- CAPTION "Crappy dialog window" MyWindow = create( Window, "This is a window ", 0, Default, Default, 400, 300, 0 ), -- "Push the button", 999, 18, 10, 80, 12 ( increased height and width some ) MyCtext = create( CText, "Push the button", MyWindow, 18, 10, 150, 15, 0 ), -- MyButton = -- "&Push me!", IDCANCEL, 18, 25, 75, 15 create( PushButton, "&Push me!", MyWindow, 18, 25, 75, 15, 0 ) -- FONT 8, "MS Sans Serif" -- setFont( MyButton, "MS Sans Serif", 8, Bold ) -- hand control over to Windows WinMain( MyWindow, Normal ) ---------------------------< cut >--------------------------------------