Wish - Button Bar Accelerators

Re: Wish - Button Bar Accelerators

Postby TimStone » Wed Jan 06, 2010 7:34 pm

Thanks James ... I will look into that.
Tim Stone
http://www.MasterLinkSoftware.com
http://www.autoshopwriter.com
timstone@masterlinksoftware.com
Using: FWH 23.10 with Harbour 3.2.0 / Microsoft Visual Studio Community 2022-24 32/64 bit
User avatar
TimStone
 
Posts: 2930
Joined: Fri Oct 07, 2005 1:45 pm
Location: Trabuco Canyon, CA USA

Re: Wish - Button Bar Accelerators

Postby ukoenig » Wed Oct 03, 2012 10:49 pm

Any Solution in the meantime about Accelerators ?

Image

I found as well a very good solution, to convert and include hight quality Images in
Borlands Resource workshop.
I can explain, if anybody needs these informations.

@ 5, 10 BTNBMP oBtn1[1] OF oGroup1A ;
SIZE 75, 60 PIXEL 2007 ;
PROMPT "&Inventario " ;
RESOURCE "B_Med" ;
ACTION ( DLG_TEST() ) ;
FONT oFont1 ;
TOP
oBtn1[1]:lTransparent := .t.

Best Regards
Uwe :?:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: Wish - Button Bar Accelerators

Postby ukoenig » Thu Oct 04, 2012 3:14 pm

I tested oRBar:bKeyChar

It works and opens the dialog from button-action, but returns a error, closing the dialog.
I couldn't find a sample, how to use it :

// oRBar:bKeyDown = { | nKey | MsgInfo( "Down: " + Str( nKey ) ) }
// oRBar:bKeyChar = { | nKey | MsgInfo( "Char: " + Str( nKey ) ) }

// Button-function on Key < p or P >
oRBar:bKeyChar = { | nKey | IIF( nKey = 80 .or. nKey = 112, DIALOG_2(), NIL ) } // P

Ther error comes from here :

METHOD RunAction( nKey, lControl ) CLASS TRibbonBar
...
If nKey > 0
::cBufferAcc += Chr( nKey )
...

Error description: Error BASE/1081 Argument error: +
Args:
[ 1] = U
[ 2] = C P

Stack Calls
===========
Called from: .\source\classes\TRIBBON.PRG => TRIBBONBAR:RUNACTION( 1461 )
Called from: .\source\classes\TRIBBON.PRG => (b)TRIBBONBAR:KEYBMODE( 1342 )
Called from: .\source\classes\WINDOW.PRG => TWINDOW:KEYDOWN( 2634 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:KEYDOWN( 1043 )
Called from: .\source\classes\TRIBBON.PRG => TRIBBONBAR:KEYDOWN( 1005 )
Called from: => TWINDOW:HANDLEEVENT( 0 )
Called from: .\source\classes\CONTROL.PRG => TCONTROL:HANDLEEVENT( 1724 )
Called from: .\source\classes\TRIBBON.PRG => TRIBBONBAR:HANDLEEVENT( 1181 )
Called from: .\source\classes\WINDOW.PRG => _FWH( 3177 )
Called from: => WINRUN( 0 )

Best Regards
Uwe :?:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: Wish - Button Bar Accelerators

Postby ukoenig » Sat Oct 06, 2012 11:06 pm

Added in Class TRibbon :

METHOD RunAction( nKey, lControl ) CLASS TRibbonBar

local nCurrent := 0
local nTemp

::cBufferAcc = ""
::aAcc = {}


Starting with group 1, the Buttonlist is working fine now,
but moving to group 2 and back to group 1, it doesn't work anymore.
I tested to load the keys ON CHANGE, but doesn't work.

ON CHANGE ( IIF( oRBar:nOption < 3, nLastPage := oRBar:nOption, NIL ), ;
GET_KEYS(oRBar), ;

oRBar:bKeyChar = { | nKey, nFlags | ;
IIF( nKey = 84 .or. nKey = 116, DIALOG_1(), NIL ), ; // T, t
IIF( nKey = 80 .or. nKey = 112, DIALOG_2(), NIL ), ; // P, p
IIF( nKey = 82 .or. nKey = 114, DIALOG_3(), NIL ), ; // R, r
IIF( nKey = 76 .or. nKey = 108, DIALOG_4(), NIL ), ; // L, l
IIF( nKey = 68 .or. nKey = 100, DIALOG_5(), NIL ), ; // D, d
IIF( nKey = 73 .or. nKey = 105, DIALOG_6(), NIL ), ; // I, i
IIF( nKey = 83.or. nKey = 115, DIALOG_7(), NIL ), ; // S, s
IIF( nKey = 77 .or. nKey = 109, DIALOG_8(), NIL ), ; // M, m
IIF( nKey = 86 .or. nKey = 118, DIALOG_9(), NIL ), ; // V, v
IIF( nKey = 65 .or. nKey = 97, DIALOG_10(), NIL ), ; // T, t
IIF( nKey = 67 .or. nKey = 99, DIALOG_11(), NIL ) } // C, c

Best Regards
Uwe :lol:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Previous

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 29 guests