always on top style?

This is a discussion on always on top style? within the Windows Programming forums, part of the Platform Specific Boards category; im trying to make a button but my program is drawing to the screen and the button is getting erased. ...

  1. #1
    ...
    ... is offline
    Registered User
    Join Date
    Feb 2002
    Posts
    465

    always on top style?

    im trying to make a button but my program is drawing to the screen and the button is getting erased. i know its being created because i turned off the program code and the button is there and functioning.

    is there a style with the CreateWindow function that specifies always on top? i looked through the docs and couldnt find one.
    I came up with a cool phrase to put down here, but i forgot it...

  2. #2
    train spotter
    Join Date
    Aug 2001
    Location
    near a computer
    Posts
    3,859
    there is the style for dialogs

    DS_SETFOREGROUND

    but for a control ? The parent dialogs z-order is important not the controls.

    try

    SetWindowPos() and modify the z-order, HWND_TOPMOST will put the dialog on top of ALL other windows even if the focus changes.

    HWND_TOP just puts it there temporarily.

    EDIT::

    I have dialogs covered with a skin (texture) and the controls show thru without need to do anything.
    "Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
    Friedrich Nietzsche

    "I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
    George Best

    "If you are going through hell....keep going."
    Winston Churchill

  3. #3
    mustang benny bennyandthejets's Avatar
    Join Date
    Jul 2002
    Posts
    1,401
    Post your code.
    benforbes@optusnet.com.au
    Microsoft Visual Studio .NET 2003 Enterprise Architect
    Windows XP Pro

    Code Tags
    Programming FAQ
    Tutorials

  4. #4
    ...
    ... is offline
    Registered User
    Join Date
    Feb 2002
    Posts
    465
    i got it taken care of.
    I came up with a cool phrase to put down here, but i forgot it...

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Button handler
    By Nephiroth in forum Windows Programming
    Replies: 8
    Last Post: 03-12-2006, 05:23 AM
  2. Why only 32x32? (OpenGL) [Please help]
    By Queatrix in forum Game Programming
    Replies: 2
    Last Post: 01-23-2006, 01:39 PM
  3. OpenGL, loading BMP Textures?
    By Zeusbwr in forum Game Programming
    Replies: 12
    Last Post: 12-09-2004, 04:16 PM
  4. Tab Controls - API
    By -KEN- in forum Windows Programming
    Replies: 7
    Last Post: 06-02-2002, 09:44 AM
  5. Stack functions as arrays instead of node pointers
    By sballew in forum C Programming
    Replies: 8
    Last Post: 12-04-2001, 10:13 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21