It is currently Mon Sep 23, 2019 4:45 pm

All times are UTC + 1 hour




Post new topic Reply to topic  [ 44 posts ]  Go to page Previous  1, 2, 3
Author Message
 Post subject:
PostPosted: Sat Sep 09, 2006 11:39 am 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
It's not the last version.
It's a good idea.

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


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Mar 19, 2007 6:22 pm 
Offline
Enthusiast
Enthusiast

Joined: Mon May 29, 2006 11:29 am
Posts: 325
Location: BARCELONA - SPAIN
Eddy,
Where can I find your ToolBar library?
Is it updated to PB4?
Thanks in advanced for sharing.

_________________
QuimV


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Mar 19, 2007 7:06 pm 
Offline
Addict
Addict
User avatar

Joined: Tue Jul 22, 2003 5:02 pm
Posts: 1534
Location: In a long distant galaxy
Hello, you might use this include.

Code:
;-
;- TOOLBAREX.PBI
;- For PureBasic 4.0
;-

EnableExplicit

;-
;- PRIVATE FUNCTIONS
;-

Procedure.l ToolBarGadgetOpen(toolbar, offsetX, w)
  Protected t.TBBUTTON, r.RECT, pos.l, ret.l
  pos = SendMessage_(ToolBarID(toolbar), #TB_BUTTONCOUNT,  0, 0)    : ToolBarSeparator()
  ret = SendMessage_(ToolBarID(toolbar), #TB_GETBUTTON,    pos, @t) : t\iBitmap = offsetX + w
  ret = SendMessage_(ToolBarID(toolbar), #TB_DELETEBUTTON, pos, 0)
  ret = SendMessage_(ToolBarID(toolbar), #TB_INSERTBUTTON, pos, t)
  ret = SendMessage_(ToolBarID(toolbar), #TB_GETITEMRECT,  pos, @r)
  UseGadgetList(ToolBarID(toolbar))
  ProcedureReturn r\left
EndProcedure
Procedure.l ToolBarGadgetClose(toolbar)
  UseGadgetList(GetParent_(ToolBarID(toolbar)))
EndProcedure

;-
;- PUBLIC FUNCTIONS
;-

ProcedureDLL.l ToolBarDate(toolbar.l, gadget.l, offsetX.l, offsetY.l, w.l, h.l, mask.s)
  DateGadget(gadget, ToolBarGadgetOpen(toolbar, offsetX, w) + offsetX, offsetY, w, h, mask)
  ToolBarGadgetClose(toolbar)
EndProcedure
ProcedureDLL.l ToolBarButton(toolbar.l, gadget.l, offsetX.l, offsetY.l, w.l, h.l, Text.s)
  ButtonGadget(gadget, ToolBarGadgetOpen(toolbar, offsetX, w) + offsetX, offsetY, w, h, Text)
  ToolBarGadgetClose(toolbar)
EndProcedure
ProcedureDLL.l ToolBarComboBox(toolbar.l, gadget.l, offsetX.l, offsetY.l, w.l, h.l, flags.l = 0)
  ComboBoxGadget(gadget, ToolBarGadgetOpen(toolbar, offsetX, w) + offsetX, offsetY, w, h, flags)
  ToolBarGadgetClose(toolbar)
EndProcedure

;-
;- END OF FILE
;-

DisableExplicit

_________________
No programming language is perfect. There is not even a single best language.
There are only languages well suited or perhaps poorly suited for particular purposes. Herbert Mayer


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Mar 19, 2007 7:44 pm 
Offline
Enthusiast
Enthusiast

Joined: Mon May 29, 2006 11:29 am
Posts: 325
Location: BARCELONA - SPAIN
Thank You Flype,
Could You send an example of use?
Thanks a lot!! :D

_________________
QuimV


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Mar 20, 2007 12:10 am 
Offline
Addict
Addict
User avatar

Joined: Tue Jul 22, 2003 5:02 pm
Posts: 1534
Location: In a long distant galaxy
yes i can but it's already done in page -2- :wink:

Code:
#WINDOW  = 7
#TOOLBAR = 10
#GADGET1 = 1
#GADGET2 = 2

If OpenWindow(#WINDOW, 200, 100, 400, 240, "Test", #PB_Window_SystemMenu)
 
  If CreateToolBar(#TOOLBAR, WindowID(#WINDOW))
    ToolBarStandardButton(1, #PB_ToolBarIcon_New)
    ToolBarStandardButton(2, #PB_ToolBarIcon_New)
    ToolBarStandardButton(3, #PB_ToolBarIcon_New)
    ToolBarSeparator()
    ToolBarDate  (#TOOLBAR, #GADGET1, 1, 1, 120, 21, "%dd / %mm / %yyyy")
    ToolBarSeparator()
    ToolBarButton(#TOOLBAR, #GADGET2, 1, 1, 50, 21, "Exit")
    ToolBarSeparator()
    ToolBarStandardButton(4, #PB_ToolBarIcon_New)
    ToolBarStandardButton(5, #PB_ToolBarIcon_New)
    ToolBarStandardButton(6, #PB_ToolBarIcon_New)
  EndIf
 
  GadgetToolTip(#GADGET1, "DateGadget in toolbar")
  GadgetToolTip(#GADGET2, "Exit")
 
  Repeat
    Select WaitWindowEvent()
      Case #PB_Event_Menu
        If EventMenu() = 1
          Break
        EndIf
      Case #PB_Event_Gadget
        If EventGadget() = #GADGET2
          Break
        EndIf
      Case #PB_Event_CloseWindow
        Break
    EndSelect
  ForEver
 
EndIf

_________________
No programming language is perfect. There is not even a single best language.
There are only languages well suited or perhaps poorly suited for particular purposes. Herbert Mayer


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Mar 20, 2007 8:38 am 
Offline
Enthusiast
Enthusiast

Joined: Mon May 29, 2006 11:29 am
Posts: 325
Location: BARCELONA - SPAIN
:o
You are right Flype, but this example don't show the use of
ToolBarComboBox.
Thanks in advanced for your help.

_________________
QuimV


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Mar 20, 2007 5:02 pm 
Offline
Always Here
Always Here
User avatar

Joined: Thu Jun 24, 2004 2:44 pm
Posts: 5755
Location: Berlin - Germany
Simple change this line:
Code:
ToolBarDate  (#TOOLBAR, #GADGET1, 1, 1, 120, 21, "%dd / %mm / %yyyy")
To
Code:
ToolBarComboBox(#TOOLBAR, #GADGET1, 1, 1, 120, 120)
:wink:

_________________
PureBasic 5.71 | SpiderBasic 2.21 | Windows 10 Pro (x64) | Linux Mint 19.2 (x64)
Old bugs good, new bugs bad! Updates are evil: might fix old bugs and introduce no new ones.
Image


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Mar 20, 2007 7:18 pm 
Offline
Enthusiast
Enthusiast

Joined: Mon May 29, 2006 11:29 am
Posts: 325
Location: BARCELONA - SPAIN
:) Thanks ts-soft

_________________
QuimV


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Mar 31, 2009 12:01 pm 
Offline
New User
New User

Joined: Tue Mar 31, 2009 11:59 am
Posts: 1
Do you have this lib for pb4.30??


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Tue Mar 31, 2009 12:42 pm 
Offline
Addict
Addict
User avatar

Joined: Sat Jun 30, 2007 8:04 pm
Posts: 3240
I didn't even know this library existed. I'd love to play with it myself. :)

_________________
Image


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Apr 02, 2009 5:27 pm 
Offline
Addict
Addict
User avatar

Joined: Mon May 26, 2003 3:07 pm
Posts: 1477
Location: Nantes
It's open source

:arrow: new version for PB 4.30 : http://www.purebasic.fr/english/viewtop ... ht=toolbar

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


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Thu Apr 02, 2009 10:29 pm 
Offline
New User
New User

Joined: Fri Mar 27, 2009 8:48 am
Posts: 8
Thank you :D


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Fri Apr 03, 2009 4:18 am 
Offline
Addict
Addict
User avatar

Joined: Sat Jun 30, 2007 8:04 pm
Posts: 3240
Thanks. :)

_________________
Image


Top
 Profile  
Reply with quote  
 Post subject: Re: Libs : ToolbarPlus
PostPosted: Mon Aug 05, 2019 1:39 pm 
Offline
New User
New User
User avatar

Joined: Fri Jun 07, 2019 1:56 pm
Posts: 1
Hi,

I downloaed the File for ToolbarPlus.

Added it as a Include to my Source and use the functions:

Code:
MyToolBar = CreateToolBar(#PB_Any, GadgetID(MyToolBarContainer),#PB_ToolBar_Large | #PB_ToolBar_Text)
If OpenToolbarGadgetList(Mytoolbar)
   ToolBarImageButton(#Toolbar_load,ImageID(Img_TabWindow_0), #PB_ToolBar_Normal , "Original-Design laden [F3]")
    SetToolBarArrow()
   SetToolBarPopup(100)
   ToolBarImageButton(#Toolbar_Save,ImageID(Img_TabWindow_1), #PB_ToolBar_Normal , "Design mit Steuerstreifen speichern [F2]")


In Eventhandling this code:

Code:
Select Event      
     Case #PB_Event_Menu
        If Event_Menu = #PB_EventType_ToolbarPopup
        DisplayPopupMenu(100,WindowID(TabWindow), ToolbarPopupX(), ToolbarPopupY())
      EndIf
      Select EventMenu()
         Case 3001 To 3030
            GetMenuItemText(100, EventMenu())
            Design_LoadFromList(GetMenuItemText(100, EventMenu()))
            Case #Toolbar_load, 1003
               Icon_Load(EventMenu())
            Case #Toolbar_Save, 1002


All is working fine as long as the source is running in runmode.

After compiling into an EXE the dropdown-arrow will not be highlighted when on it with the mouse. And when clicking to it the popupMenu will not open.
Does anyone can help me?

Thanks in advance
Rainer

More information.
the same exe-file is running an my dell laptop as it should on the hp pc with the described error.


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

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 5 guests


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