Print Page | Close Window

CXTPPropertyGridInplaceButton no show

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=7666
Printed Date: 13 November 2025 at 7:59am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: CXTPPropertyGridInplaceButton no show
Posted By: FCPM
Subject: CXTPPropertyGridInplaceButton no show
Date Posted: 25 July 2007 at 3:16pm

I use a CXTPPropertygrid to config the settings of a MDI application. Following code 1 works fine using release 1030. But when I build with version 11.3, the combo box inplace button will not show up. When you click on it. It sequentially step through all choices.

I then created a test dialog with simple code 2. It works. But when I move it into a SDI view, the in place button does not show up  either.
 
Any settings I should set?
 
Code 1:
CXTPPropertyGridItem* pATFS = new CXTPPropertyGridItem(_T("Feature Space"), _T("Fixed Dimensions"));
 
CXTPPropertyGridItem* pItemDist = pAT->AddChildItem(pATFS);
CXTPPropertyGridItemConstraints* pList = pItemDist->GetConstraints();
pList->AddConstraint(_T("Fixed Dimensions"));
pList->AddConstraint(_T("Fixed Variance"));
pItemDist->SetFlags(xtpGridItemHasComboButton | xtpGridItemHasEdit);
pATFS ->BindToString(& m_sc.m_atFeatureSpace);
 
Code 2:
 
CXTPPropertyGridItem* pSettings = m_wndPropertyGrid.AddCategory(_T("Document Settings"));
CXTPPropertyGridItem* pItemSaveOnClose = pSettings->AddChildItem(new CXTPPropertyGridItemBool(_T("SaveOnClose"), TRUE));

pSettings->Expand();

 
 



Replies:
Posted By: Oleg
Date Posted: 26 July 2007 at 7:08am
Hello,
 
Do you use custom paint manager ?


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


Posted By: FCPM
Date Posted: 26 July 2007 at 9:07am
Thanks for the reply.
 
I am drawing a control myself. So I put in XTP_PGS_OWNERDRAW into the grid windows style. And that cause the problem.
 
 


Posted By: Oleg
Date Posted: 27 July 2007 at 12:14pm
Hello,
 
yes, please add line

  CRect rcValue(rcCaption.right, rc.top, rc.right, rc.bottom - 1);
  if (!pItem->IsCategory() && bSelected)
   pGrid->GetPaintManager()->DrawInplaceButtons(&dc, pItem, rcValue);
 
to draw buttons in your custom paint manager.


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



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