10

I would want to have tabs like here (all are glass): enter image description here

A program is written in Delphi or C++ Builder. I can't find a class of the tabs in Winspector Spy & Window Detective.

I know a very good component - rkAeroTabs, but unfortunately it doesn't show an active tab with glass (that's what I need), & other tabs are not fully glass: enter image description here
(source: rmklever.com)

Does anybody know how to get those glass tabs? Thanks.

Glorfindel
  • 21,988
  • 13
  • 81
  • 109
maxfax
  • 4,281
  • 12
  • 74
  • 120
  • The component you refer has a 'LevelTabActive' property which is supposed to set opacity of the active tab. – Sertac Akyuz Jan 06 '12 at 08:15
  • I'm about rkAeroTabs. There is a wrong caption, rkAeroTabs component is on the picture, not rkSmartTabs. – maxfax Jan 06 '12 at 08:22
  • 1
    It's more complicated because there is always an intersection of the active tab with some inactive. Making it "glass" or better to say transparent will cause that you will see the part of an inactive tab (see [`here`](https://skydrive.live.com/redir.aspx?cid=198cbd603f4d4d09&resid=198CBD603F4D4D09!136&parid=198CBD603F4D4D09!115&authkey=!AGTb7dG6aheqFvY)). Workaround this will need deeper modifications. And there is also an unpleasant artifact which you can see also in your screenshot; there is a solid rectangle behind the control colored by `ColorBackground`. – TLama Jan 06 '12 at 09:23
  • 2
    To remove the solid rectangle behind the control you can publish the `FTransparent` property field. By setting it to True the background become transparent (see [`here`](https://skydrive.live.com/redir.aspx?cid=198cbd603f4d4d09&resid=198CBD603F4D4D09!137&parid=198CBD603F4D4D09!115&authkey=!ACbSVMe_irdCJPM)). – TLama Jan 06 '12 at 10:39
  • +1 to the question, they are nice looking tabs for gui important applications :) –  Jan 06 '12 at 16:28
  • It's so interesting for me how an author has made those tabs. He uses LMD, TMS, Jedi components in the app but they don't have such tabs. – maxfax Jan 06 '12 at 17:07
  • Thanks TLama for your attempts to improve a view of tabs and advices – maxfax Jan 06 '12 at 17:09
  • possible duplicate of [Google Chrome tabs style UI in Delphi](http://stackoverflow.com/questions/3924720/google-chrome-tabs-style-ui-in-delphi) – Warren P Jan 06 '12 at 17:19
  • Are you asking about how to put the tabs in the non-client area at the top of the form, or are you asking about how to make them paint over glass? rkSmartTabs already works, but setting up a fully-user-managed non-client area is also required. See the linked duplicate for details. The vaguest part of your question is what you mean by fully-glass? You want more like 50% transparency? – Warren P Jan 06 '12 at 17:21
  • I know how to put the tabs in the non-client area - http://delphihaven.wordpress.com/2010/04/19/setting-up-a-custom-titlebar I'm asking about how to make GLASS tabs on a GLASS form (not the transparent tabs; the tabs must be like on the first picture - glass). – maxfax Jan 06 '12 at 17:31
  • @Tlama, those links are asking me to sign in to something. Can you post your pictures publicly instead, please? – Rob Kennedy Jan 06 '12 at 18:02
  • maxfax: The active tab is colored blue and is 100% non-opaque, so by what definition is the active tab being painted in a "glass" manner? What on earth do you mean by 'glass'? it's an aero rendering effect involving (guess what!?) TRANSPARENCY. – Warren P Jan 06 '12 at 19:34
  • ok. Finally, all the tabs (except the active one) look like glass (many effects are used to get that glass effect, not only transparency like in rkAeroTabs/rkSmartTabs). I need glass tabs, not transparent ones. If you want you can install that app and see a difference, and the difference is big. – maxfax Jan 06 '12 at 19:51
  • @Rob, my apologies, here they are: Transparent tab, solid background is [`here`](https://skydrive.live.com/redir.aspx?cid=198cbd603f4d4d09&resid=198CBD603F4D4D09!136&parid=198CBD603F4D4D09!115) and the same with the transparent background [`here`](https://skydrive.live.com/redir.aspx?cid=198cbd603f4d4d09&resid=198CBD603F4D4D09!137&parid=198CBD603F4D4D09!115). – TLama Jan 07 '12 at 11:36
  • The difference is NOT big. It's subjective and non-apparent. Does glass equal "blue" somewhere in your brain? – Warren P Jan 07 '12 at 14:40
  • 1
    @maxfax, go to `TrkAeroTabs.SetColors` and modify the line `Brushes[2] := TGPSolidBrush.Create(MakeColor(255, Byte(c), Byte(c shr 8), Byte(c shr 16)));` to `...MakeColor(200, Byte(c), Byte(c shr 8), Byte(c shr 16))...` where 200 means the transparency of the active tab color. I don't know how would you paint a glass effect over a non-transparent element. – TLama Jan 08 '12 at 17:25
  • That's how I made my screenshots (but with lower value for the transparency) ;) – TLama Jan 08 '12 at 17:33
  • I'm a little confused as to why this question was closed by Will. How is it not constructive? – norgepaul Dec 13 '12 at 09:59

2 Answers2

9

I've just completed a pretty much complete implementation of Chrome Tabs for Delphi.

enter image description here

The features include:

  • Fully configurable Look and Feel including gradients, transparencies and custom tab shapes
  • Works on Vista glass
  • Tab movement animation
  • Tab transitional style effects (fade between colours and alpha levels)
  • Drag and Drop within container and between containers
  • Drag image displays tab and any TWinControl
  • Smart tab resizing when user clicks close button
  • Fluid tab resizing with minimum and maximum tab sizes
  • Add tab button can be positioned on the left, right or floating right
  • Full featured scrolling including auto scroll when dragging
  • Smart tab content display hides/shows items depending on the tab width
  • Owner draw any item
  • Right to Left text
  • Pinned tabs
  • Modified tabs with animated glow
  • Tab images and overlay images
  • Mouse over glow
  • Lots of events
  • Load/save look and feel and options to stream/file
  • Generate look and feel/options Delphi code

You can download the source and a full demo/editor here: http://code.google.com/p/delphi-chrome-tabs/

norgepaul
  • 6,013
  • 4
  • 43
  • 76
1

As pointed out by @Sertac Akyuz:

the rkSmartTabs has properties to set the tabs opacity levels.

LevelTabActive, LevelTabHot and LevelTabInActive.

By changing the default values (255, 192 and 224 respectivly) you can alter the opacity of different tab states.

I've been playing with it for a couple of weeks now. I really like what Roy has done with them.

Vivian Mills
  • 2,552
  • 14
  • 19
  • OP wants that for `rkAeroTabs` not `rkSmartTabs` ;) – TLama Jan 06 '12 at 16:13
  • @TLama: no he mentions rkAeroTabs. What, I think, he's looking for is a pagecontrol type of component that is glass enabled. Using rkSmartTabs, similar to tabcontrol, he can get the Glassy tabs and then using something like panels or frames(?) switch between them to get the glass look on the form. I haven't found a Glass capable pagecontrol equivilent. rkSmartTabs (same author) I know that hey can do the glass looking tabs using what I mentioned. – Vivian Mills Jan 06 '12 at 20:20
  • Of course he do. You are talking about the `rkSmartTabs` in your answer :) – TLama Jan 08 '12 at 17:20