Issues with bitmaps as constraints |
Post Reply |
Author | |
nguyena1
Groupie Joined: 28 November 2005 Status: Offline Points: 16 |
Post Options
Thanks(0)
Posted: 22 August 2008 at 3:18pm |
Hello all
I was wondering if any of you guys have ran into an issue like this. I'm trying to do a griditemenum with bitmaps for the constraints. I can get the bitmaps to show up in the list box portion but in the actual edit box portion, where the bitmap is suppose to appear, constraint string appears instead. Screenshots: When i take focus off of the edit box portion and click on another cell, the "psuedo bitmap with my string constraint in it" dissapears and the string contraint only shows. What I'm doing here works fine with the sample project "PropertyGrid" so I know its something I'm doing wrong. I have derived classes from cxtppropertygriditemEnum and numerous things that may be setting flags on this griditem that I'm not sure about. Just wondering if anyone has ran into this and knows what causes this problem. Code snippet of what I'm doing. CPropertyTabGridItemLineStyleCB::SetupBitmapConstraints(vector<HBITMAP> & myBitmaps, int nWidth, int nHeight) { //set up images into imagemanager CImageList ImageList; ImageList.Create(nWidth, nHeight, ILC_COLOR4 | ILC_MASK, myBitmaps.size(), 10); m_pTab->GetPropertyGrid().GetImageManager()->SetMaskColor(0xC0C0C0); for (int i = 0; i < myBitmaps.size(); i++)\ { CBitmap* btImage = CBitmap::FromHandle(myBitmaps); ImageList.Add(btImage, RGB(0,50,255)); } m_pTab->GetPropertyGrid().GetImageManager()->SetIcons(ImageList,0,0,CSize(nWidth, nHeight)); //add the contraints now for (int i = 0; i < m_pTab->GetPropertyGrid().GetImageManager()->GetImages()->GetCount(); i++) { CString strValue; strValue.Format("%d", i); GetConstraints()->AddConstraint(_T(strValue), i, i); { } Much appreciated Tony |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |