Print Page | Close Window

Real client area size?

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Toolkit Pro
Forum Description: Topics Related to Codejock Toolkit Pro
URL: http://forum.codejock.com/forum_posts.asp?TID=22180
Printed Date: 17 June 2025 at 10:40pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Real client area size?
Posted By: ATRML
Subject: Real client area size?
Date Posted: 24 January 2014 at 6:04pm
I'm using a ribbon as well as the docking pane manager to create my UI.

My problem is that I want to dynamically compute the client area of my frame window that is NOT occupied by the ribbon or any docking pane windows.  However, calling GetClientRect() or using CXTPClientRect always gives me the full client area of the window (0, 0, width, height), which some of you know is the /entire/ window due to the way the ribbon is rendered.

I will do some research into CXTPDockingPaneManager and CXTPCommandBars to see if there are facilities there that do what I want, but I was hoping someone here could point me in the right direction before I spend time doing that work.

I am a little confused why CXTPFrameWnd (or its base classes) don't override GetClientRect() to emulate the rectangle left over after XTP has rendered its UI elements.



Replies:
Posted By: Willowmaster
Date Posted: 28 January 2014 at 5:30am
Maybe first call a RecalcLayout or RedrawPanes before calling .GetClientRect? Documentation states that GetClientRect should be the thing you want. You could use the .GetLayout and iterate all the panes and their clientrects to determine the free space, but that's quite a hassle.

-------------
Product: Xtreme SuitePro (ActiveX) version 15.3.1

Platform: Windows XP (32bit) - SP 3 (on VMWare)

Language: Visual Basic 6.0






Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net