It is currently Thu Sep 19, 2019 11:43 am

All times are UTC + 1 hour




Post new topic Reply to topic  [ 44 posts ]  Go to page 1, 2, 3  Next
Author Message
 Post subject: Libs : ToolbarPlus
PostPosted: Mon Aug 01, 2005 7:44 pm 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
:arrow: new version for PB 4.30 : http://www.purebasic.fr/english/viewtop ... ht=toolbar

Download library (OLD VERSION) : ToolbarPlus.zip ( Extract to your PB folder and restart your PB compiler. )

Its a hack of PB standard toolbar. It's an improved version of my tip : old tip

features:
- toolbar popupmenu
- toolbar arrow
- toolbar space
- toolbar combobox
- toolbar string ( returnkey detection)
- toolbar text
- toolbar button
- toolbar checkbox
- toolbar custom popup proc
- toolbar toggle group
- bug fixed : windowblind ( or skinned ) toolbar --> visual bug
- bug fixed : broken PB event gadget
- bug fixed : if toolbar is in container gadgetlist

Image


Last edited by eddy on Wed Jun 17, 2009 12:51 am, edited 22 times in total.

Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Aug 02, 2005 8:02 am 
Offline
Addict
Addict
User avatar

Joined: Wed Apr 30, 2003 8:15 am
Posts: 983
Location: Germany
Yes, works fine here ( winxp, sp2 )


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Aug 02, 2005 11:44 pm 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
Quote:
Yes, works fine here ( winxp, sp2 )

great :)
I need windowblind users too


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Aug 02, 2005 11:55 pm 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
[ UPDATED ]
new betatest version:
- returnkey event for string gadget
- dropdown arrow
- popup menu
- bug fixed : gadget events

Code:
;toolbar popup menu
ToolBarStandardButton(1, #PB_ToolBarIcon_New)
ToolBarToolTip(1,"here : dropdown menu")
SetToolBarArrow(#True)
SetToolBarMenu(1)

ToolBarStandardButton(2, #PB_ToolBarIcon_New)
ToolBarToolTip(2,"here : dropdown menu (separated arrow)")
SetToolBarArrow(#False)
SetToolBarMenu(1)

ToolBarStandardButton(3, #PB_ToolBarIcon_New)
ToolBarToolTip(3,"here : dropdown menu (button)")
SetToolBarMenu(1)

;toolbar space
ToolBarSpace(10)

;toolbar combobox
If ToolbarCombobox(4,0,0,100,100,0)
   AddGadgetItem(4,-1,"combo 1")
   SetGadgetState(4,2) 
EndIf

;toolbar string
ToolbarString(5,0,0,70,21,"blabla",0)


Last edited by eddy on Thu Aug 04, 2005 3:37 pm, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Aug 03, 2005 8:48 am 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
[RELEASED]

version 1.0


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Aug 03, 2005 9:36 pm 
Offline
Addict
Addict
User avatar

Joined: Fri Feb 25, 2005 1:01 am
Posts: 806
Location: France > Rennes
Good job Eddy !


Top
 Profile  
Reply with quote  
 Post subject: well done
PostPosted: Thu Aug 04, 2005 10:24 am 
Offline
User
User
User avatar

Joined: Fri Mar 26, 2004 1:47 pm
Posts: 39
Location: London, UK
Excellent job Eddy - just what I needed.

I had coded some of this functionality using this approach:
Code:
CreateGadgetList(hndToolBar)
ComboBoxGadget(#gCmbZoom,210,2,50,150,#PB_ComboBox_Editable)


But your lib is much handier :)

Any plans for allowing icons in menuitems?

Thanks,
pantsonhead


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Aug 04, 2005 1:56 pm 
Offline
Addict
Addict
User avatar

Joined: Fri Feb 13, 2004 12:45 am
Posts: 2786
Location: Bergen, Norway
WPW, that is really cool.
Great work eddy :)

_________________
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Aug 04, 2005 3:39 pm 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
Thx :)

pantsonhead wrote:
I had coded some of this functionality using this approach:
Code:
CreateGadgetList(hndToolBar)
ComboBoxGadget(#gCmbZoom,210,2,50,150,#PB_ComboBox_Editable)

But your lib is much handier :)
Any plans for allowing icons in menuitems?

Me too, I used the same approach in my first version but I had some problems to maintain PB events.

Menu icons ? perhaps


Last edited by eddy on Wed Aug 10, 2005 2:47 am, edited 1 time in total.

Top
 Profile  
Reply with quote  
 Post subject: Menu lib
PostPosted: Fri Aug 05, 2005 3:21 pm 
Offline
User
User
User avatar

Joined: Fri Mar 26, 2004 1:47 pm
Posts: 39
Location: London, UK
I guess "Menu icons" should really be in a Menu lib

These are the functions I would like to see wrappered in a Menu lib.
Any other suggestions?

Code:
Procedure.b MenuSetCheckImages(hMenu.l, MenuItem.l, img1ID, img2ID)
  result.b=#False
  If IsImage(img1ID) And IsImage(img2ID)
    result= SetMenuItemBitmaps_(hMenu,MenuItem,#MF_BYCOMMAND,UseImage(img1ID),UseImage(img2ID))
  EndIf
  ProcedureReturn result
EndProcedure
     
Procedure.b MenuModifyAsBmp(hMenu.l, item.l, imgID)
  result.b = #False
  If IsImage(imgID)
    result =  ModifyMenu_(hMenu, item, #MF_BITMAP, item, UseImage(imgID))
  EndIf
  ProcedureReturn result
EndProcedure

Procedure.s GetMenuItemText(menu,item)
  b$=Space(127)
  a=GetMenuString_(menu,item,@b$,127,#MF_BYCOMMAND)
  ProcedureReturn Mid(b$,1,a)
EndProcedure


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Fri Aug 05, 2005 3:27 pm 
Offline
Addict
Addict
User avatar

Joined: Fri Feb 13, 2004 12:45 am
Posts: 2786
Location: Bergen, Norway
How about a lib with Office XP style menus?

_________________
I Stepped On A Cornflake!!! Now I'm A Cereal Killer!


Top
 Profile  
Reply with quote  
 Post subject: additions to Toolbar lib
PostPosted: Fri Aug 05, 2005 3:59 pm 
Offline
User
User
User avatar

Joined: Fri Mar 26, 2004 1:47 pm
Posts: 39
Location: London, UK
Hi again Eddy,

Perhaps the radio/toggle toolbar button stuff would be a good addition to your lib.

Example code here:
http://forums.purebasic.com/english/viewtopic.php?t=10090

Maybe you could put this in version 1.1 :wink:


regards,
pantsonhead


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Aug 10, 2005 3:07 am 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
W.I.P - version 1.1
- toolbar checkbox
- toolbar custom popup proc
- toolbar toggle group
- bug fixed : if toolbar is in container gadgetlist
- bug fixed : unwanted toolbar events

_________________
Imagewin8.1 x64 5.31 | IDE | PB plugin | Tools | Sprite | JSON | visual tool


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Aug 10, 2005 11:42 am 
Offline
Enthusiast
Enthusiast
User avatar

Joined: Tue Feb 24, 2004 3:43 am
Posts: 538
Location: Israel
Thanks! great util! :)


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Aug 10, 2005 5:33 pm 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
:)

I updated the app test. (look above)

custom popup example :
Image

_________________
Imagewin8.1 x64 5.31 | IDE | PB plugin | Tools | Sprite | JSON | visual tool


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 44 posts ]  Go to page 1, 2, 3  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  

 


Powered by phpBB © 2008 phpBB Group
subSilver+ theme by Canver Software, sponsor Sanal Modifiye