Welcome back and hope you are recovered from your jetlag! Glad the conf went well looked like a good time - hope to make it next time.
I am experimenting with the ClientArea paremeter of TABX. I am unclear exactly how to get it to work or how it works within the scheme of the entire tab. I am aware that TABSTRIP exists and i tried to compil it however it is squealing about an unmapped variable that is indeed mapped so i didnt get it running but am looking at the code.
So question - what happens to the controls within the tabx it is only a strip? Well ill tell you, they go away, presumably because the panel no longer exists. I was hoping it would "remember" that the panel is there but invisible. Which brings up question 2:
panelBorder=0/1: What is the difference b/w ClientArea and this? Now i am guessing you're going to say that panelborder KEEPS the original panel size parameter and just suppresses the border of which it does appear to do. So should I be using this instead?
Lastly: for the life of me i cannot figure out how to get either forcedSize or fixedTabs to work. What value am I supposed to use? millicols? nothing seems to corrlate. What i would like is fixed tabs of x size. What should i be using?
Woah Sailor! That's a lot to take in! Between the fact that I haven't looked at that code in quite awhile (TABSTRIP dates to 2012!), not being completely back up to speed, and my natural tendency towards incrementalism, I'm going to bite off one piece at a time, starting with an updated TABSTRIP.BP (which now compiles).
Next bite: I managed to get fixedTabs to work, but it wants to spread out all the tabs across the available space. If you want to see that in action, make this change to the TABSTRIP program:
Code
case -405 ! next style button
status = 1
do while curstyle < 200 and status # 0
curstyle += 1
! tabdefs$ = "@style="+str(curstyle)+"~~"
tabdefs$ = "@style="+str(curstyle)+"~fixedTabs=1~~" ! fixed width (or height) tabs
Another bite: I cannot get the forcedSize feature to work. It appears to do something, but mostly causes the layout to blow up. The units are supposed to be millicolumns (for horizontal tabs) or millirows (for vertical tabs), or pixels (if MBF2_PIXSIZE set). But none of them seem to work as advertised. I'll see if I can get more info on that but in the meantime I advise not wasting your time.
The same appears to apply to the panelBorder option. The control's reference manual describes it as: "do/don't display clientarea border - select styles only" but doesn't say which styles or give any visual examples. I'll see if I can probe for more details.
Thanks Cap! Sorry to send you down the rabbit hole! FWIW panelborder option does appear to work on style=66 (buttons only) which coincidentally is the one i am playing with. I was just curious b/w the this and the clientarea option.
And finally, back to your original self-answered question: If you set ClientArea=0, then there is no client area, and thus, no controls within it. It sounds like you are trying to toggle the client area off and on? If so, I think that would have to be something managed by the app. I guess theoretically it would be possible for the control to hide the panel, but that's not something I could easily override.
No not really, i an actually trying to replace the panel with just a row of buttons! I understand why the client area = 0 would actually supress the panel, so yes, thanks that makes sense.
HOWEVER -
I am playing with STYLE=60 Which indeed is just a row of buttons. After pulling out whatever hair i have left i have also discovered that for some reason I cannot change the button colors or the panel color. To prove this i ran TSTTABX and lo and behold when you get to style=66 your colors disappear. Can you tell me why this would be the case? I thought i was almost there with this style but if i cannot control the color scheme i am back to the drawing board... tx
I think the trick with Styles 66-74 is that they want to use the Windows Theme, which overrides your colors. But you can disable that by setting themes=0 ...
Code
tabdefs$ += "themes=0~" ! turn off themes
I also got a clarification on the ForcedSize option. The documentation was not complete on that and it requires a minor A-Shell update to make it work, but it doesn't work the way you probably want. For horizontal tabs like in the example above, it sets the height, not the width. For vertical tabs it sets the width. (So if you wanted to have a vertical stack of tab buttons, you could control the width of them.) But there doesn't seem to be any option for setting the width of horizontal tabs other than evenly spaced across the entire width, or spaced according to their text.
BOOM! That was it thanks for sorting that out! I can now control the colors of style = 66. (not to be confused with Order 66 though that might be my inhouse project name! )
Ok for sizing - so all i would like to do is set a fixed width of each button so it looks more uniform.. so this is not possible? (fixedTabs=1 looks like it spreads out the tabs evenly across the screen so no joy there) If not possible not the end of the world.
I can confirm that ForcedSize works with millirows.
That appears to be the case, i.e. the only two options are to spread the buttons out uniformly across the entire width of the panel, or let them size naturally (but unequally, depending on the text). I've put in an inquiry to the control developer, but can't guarantee any rapid or particular response.
Here's a possible back-end way to get fixed width tabs of a desired size. If you set fixedTabs=1 it spreads them across the entire width of the panel. But you can override the number of tabs that it bases its width on by setting rows=#. So for example, here's the default style 66 with 3 tabs ...
And here is is with:
Code
tabdefs$ += "fixedTabs=1~" ! fixed width tabs
tabdefs$ += "rowTabs=7~" ! set tab width at overall / 7
tabdefs$ += "ForcedSize=1500~" ! set height to 1.5 rows
Note that the ForcedSize option may require an A-Shell update; if so, just remove that for now until I can clean up the latest batch of patches. Also note that this may only be convenient for a single row of tabs, i.e. where the actual number is less than the rowTabs value that you specify.
Good day - I am hijacking my own thread here because i think it applies...
I am trying to change the font on the panel and get more of a BOLD look but I cannot seem to and I am not sure it is supported. There are a few font attributes in the docs but none are BOLD although there is a BOLD=0/1 but i believe it applies to just the "selected" tab.
Current setup is this:
! Preset Main Program Global Attributes MAIN'GLOBAL'ATTR="@style=66~" MAIN'GLOBAL'ATTR+="themes=0~" MAIN'GLOBAL'ATTR+="Font=Arial~" MAIN'GLOBAL'ATTR+="FontScale=90~" MAIN'GLOBAL'ATTR+="bold=1~" MAIN'GLOBAL'ATTR+="panelBorder=0~"
I am trying to achieve the first style and can only get the second.
I suggest going into the standard font selection dialog (from any app, including A-Shell < Settings > Font) and just looking at what seems to be more bold/compact. Arial is at the opposite extreme, tall and slender. Some stockier/bolder choices might be: Aptos, Arial Rounded MT, Franklin Gothic, Roboto, Verdana.
Obviously you want to pick something that isn't too exotic so that it is likely to exist on most target systems, but if it doesn't exist, the font mapper will revert to something else (probably Arial).