Hi Mike,
For “how to you get the size of the tabs” issue,
I don't quite understand why you need to do this. If only to control the current MDI client area to display other controls properly in the frame window resize event, I think not using the height of tabbedbar will not affect the layout either.
In addition, the MDI client area size is bound to the tabbedbar control. When a sheet is opened, the y value of the MDI client automatically increases and its height automatically decreases by one of the height of the tabbedbar.
When all sheets are closed, the y value of the MDI client automatically decreases and the height value automatically increases by one of the height of the tabbedbar.
If static interface layout registration is involved similar to FPC framework, then the problem is really difficult to deal with. Because after opening the Tabbedview function, the corresponding window built-in mditbb_1 control is a hidden object. The default height value is 0, and the actual height can only be taken in runtime. If your application does not involve dynamically adjusting the font type or size of the Tabbedview function, the height of the mditbb_1 control is a fixed value before and after the run, which is easier to work around.
If you think my understanding on this problem is incorrect, we might not be on the same page. Please provide a sample reproducible test case(including PBT/PBL) to us for more study. Thanks.
For “how to do you get whether the tabs are displayed” issue, it will be improved in the next version and corresponding new solution will be provided to solve it.
For your two problems, you can refer to Bruce’s example code in the following link to work around.
https://community.appeon.com/index.php/qna/q-a/pfc2022-resize-service-doesn-t-work-right-in-mdi-with-tabbedview
integer li_rc, li_index, li_count
w_frame lw_frame
string ls_classname
integer li_tabheight = 0
// Resize objects...
lw_frame = gnv_app.of_getframe( )
li_count = UpperBound ( lw_frame.control )
FOR li_index = 1 TO li_count
ls_classname = ClassName ( lw_frame.control[li_index] )
IF ls_classname = 'mditbb_1' THEN
li_tabheight = 104
END IF
NEXT
dw_1.Width = this.WorkSpaceWidth() - 40
dw_1.Height = this.WorkspaceHeight() - ( 40 + li_tabheight )
// Window Resize Behavior
li_rc = this.of_SetResize(true)
li_rc = this.inv_resize.of_Register(dw_1, inv_resize.scalerightbottom)
mditbb_1 - what TYPE is it? mdi_1 is MDICLIENT
there is no documentation on this, doesn't show up in the object browser either. the help is terrible. The examples should have hyperlinks to actual object definitions for the mditbb_1 ( i can only see from the online help of R3).
the height of the mditbb_1 should reflect at runtime the height of mditbb_1 . Or, failing that, the visible property should be true/false depending on whether the tabs are showing or not. (close all sheets and the tab goes away). It should be both. I see nothing in the 'what's new' about that being addressed.
In any case, the documentation should state exactly what happens with mdiclient. It is clear that mdiclient is now adjusted when the mditbb is used despite the documentation saying that it is not adjusted when you have objects on the frame. It should have been consistent with everything else, but here we are, so at least document it.
Thank you for your feedback and detailed explanation.
We agree with your point of view, and we will notify the documentation team to update the relevant information.