quaizywabbit Posted July 24, 2005 Share Posted July 24, 2005 is there a way to get the actual client area of a tabitem? or is there a standard offset from the tab itself? [u]Do more with pre-existing apps![/u]ANYGUIv2.8 Link to comment Share on other sites More sharing options...
GaryFrost Posted July 24, 2005 Share Posted July 24, 2005 User Defined functions: _GUICtrlTabGetItemRECT -------------------------------------------------------------------------------- Retrieves the bounding rectangle for a tab in a tab control. #Include <GuiTab.au3> _GUICtrlTabGetItemRECT($h_tabcontrol, $i_item) Gary SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
quaizywabbit Posted July 24, 2005 Author Share Posted July 24, 2005 Thanks Gary! [u]Do more with pre-existing apps![/u]ANYGUIv2.8 Link to comment Share on other sites More sharing options...
quaizywabbit Posted July 25, 2005 Author Share Posted July 25, 2005 (edited) it returns the Left, Top, Right, and Bottom for the tabitem button, not the client area below it.. could you add a func that returns the Client area? (i.e. left, top, width, height) It would help alot when setting things like a background bitmap(or other controls) to fit the client area boundaries... Edited July 25, 2005 by quaizywabbit [u]Do more with pre-existing apps![/u]ANYGUIv2.8 Link to comment Share on other sites More sharing options...
GaryFrost Posted July 25, 2005 Share Posted July 25, 2005 ok, my bad, might want to look into TCM_ADJUSTRECT at msdnCalculates a tab control's display area given a window rectangle, or calculates the window rectangle that would correspond to a specified display area. You can send this message explicitly or by using the TabCtrl_AdjustRect macro.SyntaxTo send this message, call the SendMessage function as follows. lResult = SendMessage( // returns LRESULT in lResult (HWND) hWndControl, // handle to destination control (UINT) TCM_ADJUSTRECT, // message ID (WPARAM) wParam, // = (WPARAM) (BOOL) fLarger; (LPARAM) lParam // = (LPARAM) (LPRECT) prc; ); ParametersfLargerOperation to perform. If this parameter is TRUE, prc specifies a display rectangle and receives the corresponding window rectangle. If this parameter is FALSE, prc specifies a window rectangle and receives the corresponding display area. prcPointer to a RECT structure that specifies the given rectangle and receives the calculated rectangle. Return ValueNo return value.Gary SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
GaryFrost Posted July 25, 2005 Share Posted July 25, 2005 here's the values needed for the function call Global Const $TCM_FIRST = 0x1300 Global Const $TCM_ADJUSTRECT = ($TCM_FIRST + 40) SciTE for AutoItDirections for Submitting Standard UDFs Don't argue with an idiot; people watching may not be able to tell the difference. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now