Page 7 of 13
Re: TabBarGadget - Tabs like in a browser
Posted: Sat Jul 12, 2014 7:50 pm
by staringfrog
oh, the pleasure is all mine!
yes, I am testing your marvelous gadget at the moment, among other things, against "clickable text labels" (that I use instead of standard win panel gadget, due to irksome flicker effect on old Windows). See, when you've got a set number of tabs (say, three or five) and your form's resizable (and so are your tabs, with #TabBarGadget_MinTabLength flag, right), those tabs can get really wide, so that text labels need some alignment.
All in all, I can state your library is jolly well shaped, as it is! I hope no one would get hurt if I say that somehow German people seem to be the best in that old gadget-crafting business

(as I judge from my humble experience).
Re: TabBarGadget - Tabs like in a browser
Posted: Mon Jul 14, 2014 11:55 pm
by Poshu
For the record, I'm using it too and I love it. Never had anything to complain so I did not post here, but it is, imho, one of the very best gadget out there.
Re: TabBarGadget - Tabs like in a browser
Posted: Sat Jul 19, 2014 12:59 pm
by STARGÅTE
Short feedback from my side.
I'm working at the moment on the next beta version of 1.5 and I add this featurs:
- Individual attributes for tabs: close button, check box (@staringfrog, and many more users)
- new attribute: #TabBarGadget_SelectedCloseButton to display only on the selected tab a close button (@kenmo)
- alignment (left, center, right) for tab text (@staringfrog)

Is this right staringfrog?
Please post more featurs for the next beta, before I publish. Thx.
Re: TabBarGadget - Tabs like in a browser
Posted: Sun Jul 20, 2014 12:00 am
by STARGÅTE
thx Louise
- "1- pin and unpin tab. like firefox 30.0"
This feature is for a future version.
- "RightToLeft Property"
Yes, an attribute to inverse the tab order.
- "DrawFocusRect Property"
You mean the focus rectangle from the canvas gadget (#PB_Canvas_DrawFocus)?
- "Appearance Property"
I think, this can be a copyright issue!
But I had the idea to define the appearance with XML (optional).
SetTabBarGadgetAppearance(), and in the XML fiel you can define paddings, margins, positions, borders, and images for normal, active, hovered, ... tabs.
But this featurs is also for a future version.
- "BoldSelected Property"
See previous point.
- "English help"
Really right, and I work at the moment on the translation.
Re: TabBarGadget - Tabs like in a browser
Posted: Sun Jul 20, 2014 12:33 am
by staringfrog
STARGÅTE,
precisely so. Individual attributes for tabs, to make do with just a single TabBarGadget in most cases. And text alignment, as soon as you enable us to draw wide tabs.
By the way, Stargate, do you use any "intelligent double buffering" (as Chris put it) in your gadget? I have noticed that active resizing of 5 TabBar tabs in a row (that is, resizing of tab widths themselves, with #TabBarGadget_MinTabLength flag, proportionally to the overall form width) isn't quite flicker-free on my themed WinXP. Again, I'm just wondering, as all those flicker-on-resize tricks appear to be my major headache on Windows (and probably these problems are not that common).
Re: TabBarGadget - Tabs like in a browser
Posted: Sun Jul 20, 2014 1:11 am
by STARGÅTE
staringfrog wrote:By the way, Stargate, do you use any "intelligent double buffering" (as Chris put it) in your gadget? I have noticed that active resizing of 5 TabBar tabs in a row (that is, resizing of tab widths themselves, with #TabBarGadget_MinTabLength flag, proportionally to the overall form width) isn't quite flicker-free on my themed WinXP.
I have testing this code:
Code: Select all
IncludeFile "TabBarGadget.pbi"
Enumeration
#Window
#Gadget
EndEnumeration
Procedure Callback()
ResizeGadget(#Gadget, 0, 0, WindowWidth(#Window), 25)
SetTabBarGadgetAttribute(#Gadget, #TabBarGadget_MinTabLength, Int((WindowWidth(#Window)-TabBarGadgetInclude\Margin)/CountTabBarGadgetItems(#Gadget)))
EndProcedure
OpenWindow(#Window, 0, 0, 800, 600, "WindowTitle", #PB_Window_MinimizeGadget|#PB_Window_ScreenCentered|#PB_Window_SizeGadget)
TabBarGadget(#Gadget, 0, 0, 800, 25, #Null, #Window)
AddTabBarGadgetItem(#Gadget, 0, "tab 1")
AddTabBarGadgetItem(#Gadget, 1, "tab 2")
AddTabBarGadgetItem(#Gadget, 2, "tab 3")
AddTabBarGadgetItem(#Gadget, 3, "tab 4")
AddTabBarGadgetItem(#Gadget, 4, "tab 5")
BindEvent(#PB_Event_SizeWindow, @Callback())
Callback()
Repeat : Until WaitWindowEvent() = #PB_Event_CloseWindow
I can't see any flicker.
Node: If you set a min tab width (depending on the gadget width) you have to subtract the tab bar margin and rounding down.
Re: TabBarGadget - Tabs like in a browser
Posted: Sun Jul 20, 2014 1:20 am
by staringfrog
I can't see any flicker.
Me neither. Thanks for your example and advice. It might be that my project form is too overloaded with resizable controls and splitters, and some are not coded/calculated correctly. Thank you for your quick reply, and hope to see your new version soon!
Re: TabBarGadget - Tabs like in a browser
Posted: Wed Aug 06, 2014 12:05 am
by STARGÅTE
I am very happy to present you the new beta (but hopefully soon final) version:
Here the download with the new include and my demo:
TabBarGadget - 1.5 Beta 2
Update 1.5 Beta 2 (6. August 2014)
- SetTabBarGadgetItemAttribute() and GetTabBarGadgetItemAttribute(): Changes or returns the attribute of a tab.
So you can add a checkbox or a close button on a single tab.
- #TabBarGadget_TabTextAlignment: Changes the alignment of the text in a tab with more space.
- #TabBarGadget_SelectedCloseButton: Add a close button only on selected tabs.
- #TabBarGadget_ReverseOrdering: Reverses the ordering of the tabs (to "right to left").
The feature is for example for arabic tab bars.
- A first version of a new online documentation in english: http://help.unionbytes.de/tbg/

Re: TabBarGadget - Tabs like in a browser
Posted: Wed Aug 06, 2014 1:13 am
by kenmo
Thank you STARGATE ("the legend")
I will definitely try it out and report any issues. I feel bad for not giving a lot of feedback on Beta 1 - but in my projects I mostly use the basic features (not Editable tabs, Checkboxes, etc.).
We all appreciate it!!
Re: TabBarGadget - Tabs like in a browser
Posted: Wed Aug 06, 2014 11:06 am
by Fred
That's really a cool component.
Re: TabBarGadget - Tabs like in a browser
Posted: Tue Sep 02, 2014 10:05 am
by Fred
The beta 2 doesn't compile on OS X or Linux, as TextGadget() in line 2543 is missing a parameter.
Re: TabBarGadget - Tabs like in a browser
Posted: Tue Sep 02, 2014 12:47 pm
by STARGÅTE
oh, I don't know why, but I have forget the "text" for the dummy TextGadget().
Code: Select all
DummyGadget = TextGadget(#PB_Any, 0, 0, 10, 10, "Dummy")
I have updated the download link.
TabBarGadget - 1.5 Beta 2
Re: TabBarGadget - Tabs like in a browser
Posted: Sun Sep 28, 2014 7:23 am
by Fangbeast
I really wish STARGÅTE's TabBarGadget and Kenmo's IconBarGadget were part of PureBasic (and all visual designers) because they are so damned cool and useful!
Would it help if I beg and sacrifice some fresh sheep to srod??
Re: TabBarGadget - Tabs like in a browser
Posted: Sun Sep 28, 2014 8:12 am
by Bisonte
STARGÅTE's TabBarGadget is a part of PureBasic IDE !
Re: TabBarGadget - Tabs like in a browser
Posted: Sun Sep 28, 2014 10:02 am
by Fangbeast
Bisonte wrote:STARGÅTE's TabBarGadget is a part of PureBasic IDE !
Gee, just what a need, a comedian.