Page 1 of 1

[PB5.10] Underline Buttontext

Posted: Sun Feb 17, 2013 8:44 pm
by ts-soft
With XP-Style enabled, the first Signs of Buttontext is underlined after pressing ALT-Key, but the
underline doesn't go away after none pressing ALT-Key.

Without XP-Style the first Signs of Buttontext is underlined without pressing anything (correct) but
the underline is gone after filerequester and doesn't come back after closing filerequester.

On Linux is never a underlined Buttontext.

Examplesource:

Code: Select all

EnableExplicit

OpenWindow(0, #PB_Ignore, #PB_Ignore, 640, 480, "")

ButtonGadget(0, 10, 10, 200, 25, "&Test Button")

Repeat
  Select WaitWindowEvent()
    Case #PB_Event_CloseWindow
      Break
    Case #PB_Event_Gadget
      Select EventGadget()
        Case 0
          OpenFileRequester("", "", "", 0)
      EndSelect
  EndSelect
ForEver
see here in german forum: http://www.purebasic.fr/german/viewtopi ... 81#p309381

Re: [PB5.10] Underline Buttontext

Posted: Sun Feb 17, 2013 10:31 pm
by User_Russian

Code: Select all

EnableExplicit

OpenWindow(0, #PB_Ignore, #PB_Ignore, 640, 480, "")

ButtonGadget(0, 10, 10, 200, 25, "&Test Button")

SetActiveGadget(0)
SendMessage_(WindowID(0), #WM_UPDATEUISTATE, $30002,0)

Repeat
  Select WaitWindowEvent()
    Case #PB_Event_CloseWindow
      Break
    Case #PB_Event_Gadget
      Select EventGadget()
        Case 0
          OpenFileRequester("", "", "", 0)
      EndSelect
  EndSelect
ForEver

Re: [PB5.10] Underline Buttontext

Posted: Sun Feb 17, 2013 11:03 pm
by VB6_to_PBx

Code: Select all


EnableExplicit

OpenWindow(0, #PB_Ignore, #PB_Ignore, 640, 480, "")

ButtonGadget(0, 10, 10, 200, 25, "&Test Button")
SetActiveGadget(0)
SendMessage_(WindowID(0), #WM_UPDATEUISTATE, $30002,0)

Repeat
    Select WaitWindowEvent()
    Case #PB_Event_CloseWindow
         Break
    Case #PB_Event_Gadget
         Select EventGadget()
         Case 0
              OpenFileRequester("", "", "", 0)
              SendMessage_(WindowID(0), #WM_UPDATEUISTATE, $30002,0)
         EndSelect
    EndSelect
ForEver

Re: [PB5.10] Underline Buttontext

Posted: Mon Feb 18, 2013 1:43 am
by ts-soft
Thanks, but this is a bugreport, i am not searching for a workaround.
This bug is new to PB5.x

Re: [PB5.10] Underline Buttontext

Posted: Mon Feb 18, 2013 10:09 am
by dige
Its not a bug, its a feature. And please do not change it
again - we had big redraw and flicker problem...

Re: [PB5.10] Underline Buttontext

Posted: Mon Feb 18, 2013 12:45 pm
by ABBKlaus
dige is correct, its not solved through the windows standard method IsDialogMessage().

PB uses somes tricks to make it visible : SetUIState()

The only thing that makes the focusrectangle disappear again is the LostFocus event.

Re: [PB5.10] Underline Buttontext

Posted: Mon Feb 18, 2013 2:56 pm
by NicTheQuick
With Linux Mint 14 x64 the text on the button is "&Open" and not "Open". This is a bug! It's the wrong bug report forum in this case, but still a bug.

Re: [PB5.10] Underline Buttontext

Posted: Mon Feb 18, 2013 3:22 pm
by ts-soft
Okay, I understand, if a Workaround generates a bug for another bug, this is no bug :?