Print Page | Close Window

ComboDropHeight (suggestion)

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=977
Printed Date: 08 November 2025 at 9:48pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: ComboDropHeight (suggestion)
Posted By: dialogik
Subject: ComboDropHeight (suggestion)
Date Posted: 25 July 2004 at 6:27am

dear staff

it would be perfect to have a possibility to control the heigt of a combobox dropdown,
the hardcoded 12 lines is not really nice. m_dropdownitemcount would be much nicer!
best regards,
christoph braendle

BOOL CXTPControlComboBoxList::Popup(CXTPControlPopup* pControlPopup, BOOL /*bSelectFirst*/)
{

SetFont(CXTPPaintManager::GetIconFont());
m_pControlPopup = pControlPopup;
CWnd* pWndOwner = GetOwnerSite();
if (pWndOwner)
pWndOwner->SendMessage(WM_XTP_INITCOMMANDSPOPUP, , (LPARAM)this);
SetTrackingMode(TRUE, FALSE);
UpdateFlags();
CRect rcControl = pControlPopup->GetRect();
int nItemHeight = ((CListBox*)this)->GetItemHeight(0);
int nHeight = min ( 12 , max(1, ((CListBox*)this)->GetCount())) * nItemHeight + 4;
int nWidth = m_nMRUWidth <= 0? rcControl.Width(): m_nMRUWidth;
SetPosition(CSize(nWidth, nHeight));
return TRUE;
}




Replies:
Posted By: Warren
Date Posted: 01 September 2005 at 5:22pm
I second this request - I just ran into this issue today.

Please add support for this!!!

Warren



Posted By: Oleg
Date Posted: 01 September 2005 at 11:51pm

Hello,

SetDropDownItemCount method added.



-------------
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS


Posted By: Barto
Date Posted: 02 September 2005 at 3:47am

Please add the same method for the PropertyGrid's InPlaceList.

I've always been patching the XTP source code, that's not a good way to do it :)




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