Forum
Please
Log In
to post a new message or reply to an existing one. If you are not registered, please
register.
NOTE: Some forums may be read-only if you are not currently subscribed to
our technical support services.
|
Subject |
Author |
Date |
|
|
gnana bhaskar
|
May 19, 2009 - 12:56 AM
|
Hello,
I am using ProfUIS223nd.dll, in my application i am getting the tool tips according to the language. my application i am using 4 languages, recently i have ported my application to Prof-UIS. I have created the dialogs , menus and toolbars in the english language only. then i have created the langaues dlls with string table. i have used the string from the resouce string only.
Now i am getting the problem with tooltips. i am not able to get tooltips of my tools.
In my application i have used for set the tooltips like below
ON_NOTIFY_EX_RANGE(TTN_NEEDTEXTW, 0, 0xFFFF, OnToolTipText)
ON_NOTIFY_EX_RANGE(TTN_NEEDTEXTA, 0, 0xFFFF, OnToolTipText)
BOOL CMainFrame::OnToolTipText(UINT nID, NMHDR *pNMHDR, LRESULT *pResult)
{
.......
}
these staments worked in MFC after porting to Prof-UIS these option are not working.
Can u please provide the solution for this.
thnx in advance
|
|
|
Technical Support
|
May 19, 2009 - 1:31 PM
|
Prof-UIS tooltips are not just repainted tooltip common controls. They are windows written from scratch. All the tooltips displayed by toolbars and menus are based on the command description objects (the CExtCmdItem class) stored in the command profile (the CExtCmdProfile class) in the command manager (the CExtCmdManager class and the g_CmdManager global smart pointer variable). You can invoke the g_CmdManager->CmdGetPtr() code to get the pointer to the CExtCmdItem object describing some command. The CExtCmdItem::m_sTipTool property contains text for tooltip displayed over toolbar buttons. You need to reload the tooltips for all the commands. How the command descriptions appear registered inside the command manager? The CExtCmdManager::UpdateFrom***() methods put the CExtCmdItem command descriptions into the command manager. These methods are typically invoked during the application initialization. The methods like CExtToolControlBar::LoadToolBar(), CExtMenuControlBar::LoadMenuBar(), CExtPopupMenuWnd::LoadMenu() and CExtPopupMenuWnd::UpdateFromMenu() are also updating the command manager. So, you can simply unregister all the commands in your command manager using the CExtCmdManager::CmdRemoveAll() method, change your preferred language and, finally, update the command manager from all the resources. The LanguageSwitcher sample application demonstrates how to change the language of the running program on-the-fly when the customization subsystem is used by toolbars and menus.
|
|
|
gnana bhaskar
|
May 19, 2009 - 12:57 AM
|
Hello,
I am using ProfUIS223nd.dll, in my application i am getting the tool tips according to the language. my application i am using 4 languages, recently i have ported my application to Prof-UIS. I have created the dialogs , menus and toolbars in the english language only. then i have created the langaues dlls with string table. i have used the string from the resouce string only.
Now i am getting the problem with tooltips. i am not able to get tooltips of my tools.
In my application i have used for set the tooltips like below
ON_NOTIFY_EX_RANGE(TTN_NEEDTEXTW, 0, 0xFFFF, OnToolTipText)
ON_NOTIFY_EX_RANGE(TTN_NEEDTEXTA, 0, 0xFFFF, OnToolTipText)
BOOL CMainFrame::OnToolTipText(UINT nID, NMHDR *pNMHDR, LRESULT *pResult)
{
.......
}
these staments worked in MFC after porting to Prof-UIS these option are not working.
Can u please provide the solution for this.
thnx in advance
|
|
|
ProfUIS User
|
May 15, 2009 - 3:46 AM
|
Hi Team, In one of the projects, I found that Mainfrm class was derived from <meta content="text/html; charset=utf-8" http-equiv="Content-Type" /> <meta content="Word.Document" name="ProgId" /> <meta content="Microsoft Word 11" name="Generator" /> <meta content="Microsoft Word 11" name="Originator" /> <link href="file:///C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\msohtml1\01\clip_filelist.xml" rel="File-List" /><!--[if gte mso 9]><xml> <o:OfficeDocumentSettings> <o:DoNotRelyOnCSS /> </o:OfficeDocumentSettings> </xml><![endif]--><!--[if gte mso 9]><xml> <w:WordDocument> <w:View>Normal</w:View> <w:Zoom>0</w:Zoom> <w:PunctuationKerning /> <w:ValidateAgainstSchemas /> <w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid> <w:IgnoreMixedContent>false</w:IgnoreMixedContent> <w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText> <w:Compatibility> <w:BreakWrappedTables /> <w:SnapToGridInCell /> <w:WrapTextWithPunct /> <w:UseAsianBreakRules /> <w:DontGrowAutofit /> <w:UseFELayout /> </w:Compatibility> <w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel> </w:WordDocument> </xml><![endif]--><!--[if gte mso 9]><xml> <w:LatentStyles DefLockedState="false" LatentStyleCount="156"> </w:LatentStyles> </xml><![endif]--><style type="text/css"> <!-- /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-parent:""; margin-top:12.0pt; margin-right:0in; margin-bottom:0in; margin-left:0in; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:Arial; mso-fareast-font-family:"Times New Roman"; mso-bidi-font-family:"Times New Roman"; mso-fareast-language:EN-US;} @page Section1 {size:8.5in 11.0in; margin:1.0in 1.25in 1.0in 1.25in; mso-header-margin:.5in; mso-footer-margin:.5in; mso-paper-source:0;} div.Section1 {page:Section1;} --> </style><!--[if gte mso 10]> <style> /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Times New Roman"; mso-fareast-font-family:"Times New Roman"; mso-ansi-language:#0400; mso-fareast-language:#0400; mso-bidi-language:#0400;} </style> <![endif]-->CExtNCW< CFrameWnd>. Isearched in Help documentation but couldn’t find any information on that. Could you please provide the actual need of this particulat base class. Thanks.
|
|
|
ProfUIS User
|
May 15, 2009 - 3:47 AM
|
Resending the problem as some HTML content came in between lines: In one of the projects, I found that Mainfrm class was derived from CExtNCW< CFrameWnd>. I searched in Help documentation but couldn’t find any information on that. Could you please provide the actual need of this particulat base class. Thanks.
|
|
|
Timo Stripf
|
May 12, 2009 - 3:11 PM
|
I have some derived CListCtrl’s and i have tried to use CExtNCSB with it, but the scrollbar doesn’t work.
Exist a fix for it to use CExtNCSB with CListCtrl. When i try to derive my class from CExtNCSB, then some linker errors occured. If i use CExtNCSB on member declaration then is the old style scrollbar active and no cextscrollwnd.
|
|
|
Technical Support
|
May 13, 2009 - 12:56 PM
|
Please drop us an e-mail to the support mail box at this web site so we can provide you with the source code update.
|
|
|
Timo Stripf
|
May 13, 2009 - 4:47 PM
|
|
|
|
|
Technical Support
|
May 15, 2009 - 8:14 AM
|
We sent you an e-mail with download details.
|
|
|
ProfUIS User
|
May 7, 2009 - 6:32 AM
|
Hi, I am trying to build ProfUIS_Controls_800.vcproj present in the samples. It is giving me ProfUIS254nd.lib linking error as it could not find the specified library. I looked inside the libraries folder but couldn’t find the file. What could be reason behind this? Which class uses this library? How can I remove this error? Thanks.
|
|
|
Technical Support
|
May 8, 2009 - 11:57 AM
|
The ProfUIS254ud.lib / ProfUIS254ud.dll files are produced by the Unicode Debug configuration of the ProfUISDLL project which can be found in the .../Prof-UIS/ProfUISDLL/ folder. Please compile this configuration of the Prof-UIS library before compiling the same configuration of any of sample applications.
|
|
|
ProfUIS User
|
May 8, 2009 - 10:53 PM
|
|
|
|
|
ProfUIS User
|
May 7, 2009 - 10:53 PM
|
Here is the error statement: 1>------ Build started: Project: ProfUIS_Controls, Configuration: Unicode DEBUG Win32 ------
1>Linking...
1>LINK : fatal error LNK1104: cannot open file ’ProfUIS254ud.lib’
1>Build log was saved at "file://c:\Program Files\FOSS Software Inc\Prof-UIS\Bin_800\UnicodeDEBUG\ProfUIS_Controls\BuildLog.htm"
1>ProfUIS_Controls - 1 error(s), 0 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
|
|
|
Technical Support
|
May 7, 2009 - 1:48 PM
|
Could you show us the content of the Visual Studio output window with the linking error?
|
|
|
ProfUIS User
|
May 7, 2009 - 6:21 AM
|
Hi, I am using CExtTabWhidbeyWnd class for creating tabs. Now I want to add Ctrl+Tab feature for shifting from one tab to another, similar to Visual Studio IDE. Could you please help me out? Thanks in advance.
|
|
|
Technical Support
|
May 7, 2009 - 1:50 PM
|
The CExtTabWnd class implements a single line or multi line control. It’s demonstrated on the Tab Window dialog page in the ProfUIS_Controls sample application. The CExtTabPageContainerWnd class implements a a container window based on the tab control. It’s demonstrated on the Tab Containers dialog page in the same sample application. The CExtTabMdiWnd class implements an MDI tab control and it’s used in the sample applications like DRAWCLI, MDI_DynamicBars and FormEditor for switching between opened MDI child frames. The last 2 controls are based on the first CExtTabWnd class used as the single line tab control in the most of cases. The CExtTabWnd class never knows where and how it’s used. So, your question is not related to tabs. We have different versions of the tab controls based on all the controls meant above. The Whidbey tab control is just one of them. Please provide us with more details about how and where you are using the Whidbey tabs? The tab page containers support the selected page switching on Ctrl+PageDown and Ctrl+PageUp keys. This is similar to what you need. We didn’t used Ctrl+Tab and Ctrl+Shift+Tab key combinations in tab containers because they are used for switching focused control in dialog windows and dialogs are the most often used page windows inside tab containers.
|
|
|
Timo Stripf
|
May 6, 2009 - 12:12 PM
|
Why are the default Messages (NM_XXX, TVN_XXX) not implemented in the CExtTreeCtrl class. It makes the work with it not realy easier, if it works only with derived class, but not realy good. It is planned to implement a working version of CExtTreeCtrl which dont need a complete rewrite of code to use it?
|
|
|
Martin Barringer
|
May 1, 2009 - 9:57 AM
|
I’m trying to use a CExtGridCellComboBox in a Property Grid and am having a problem detecting a change in the selection of an item. I’m using the CExtPropertyItem Apply() method to capture changes in my grid. This works fine for string based items but not for the combo box. The Apply method never gets called.
I’ve verified this with the Property Grid Sample supplied with Prof-UIS. Looking at the Animation combo box in the sample when you make a selection the Apply method doesn’t get called to make the change effective. You have to select another item, then click back in the Animation item (not calling the combo box), then select another item. This is the only way the Apply method gets called.
Can this behavior be changed to function as intended? Have the Apply method called once a selection in the combo box is made. Also can this be made to function when the item is set so that no inplace edit control is used. I want the item to function as a drop list. And not allow users to type in changes.
|
|
|
Technical Support
|
May 2, 2009 - 12:51 PM
|
This issue is fixed in Prof-UIS 2.85. Please drop us an e-mail to the support mail box at this web site so we can provide you with the source code update.
|
|
|
Martin Barringer
|
May 1, 2009 - 9:56 AM
|
I’m trying to use a CExtGridCellComboBox in a Property Grid and am having a problem detecting a change in the selection of an item. I’m using the CExtPropertyItem Apply() method to capture changes in my grid. This works fine for string based items but not for the combo box. The Apply method never gets called.
I’ve verified this with the Property Grid Sample supplied with Prof-UIS. Looking at the Animation combo box in the sample when you make a selection the Apply method doesn’t get called to make the change effective. You have to select another item, then click back in the Animation item (not calling the combo box), then select another item. This is the only way the Apply method gets called.
Can this behavior be changed to function as intended? Have the Apply method called once a selection in the combo box is made. Also can this be made to function when the item is set so that no inplace edit control is used. I want the item to function as a drop list. And not allow users to type in changes.
|
|
|
Douglas Hoppes
|
Apr 29, 2009 - 1:14 PM
|
Is there any way that I can disable the text change in the CExtGridCellCheckBox? I just want the user to turn off/on the text box. Even if I use SetAutoTextMode, the user can still change the text (I have the mode set to false, so that there is no text showing).
Doug
|
|
|
Technical Support
|
Apr 30, 2009 - 7:42 AM
|
The Grid dialog page in the ProfUIS_Controls sample application contains a column with check box cells. There are check boxes with and without auto changeable text in this column. These check boxes are initialized in the CPageGrid::_InitColumnCheckBox() method. The CExtGridCell::TextSet() method should be used to assign the label text to the CExtGridCellCheckBox grid cell if it does not use auto changeable label. The CExtGridCellCheckBox::LabelTextSet() should be used to assign changeable label’s text. In any case, the CExtGridCell::TextSet() and CExtGridCellCheckBox::LabelTextSet() methods should be invoked after the CExtGridCellCheckBox::SetAutoTextMode() method.
|
|
|
Dirk lindner
|
Apr 29, 2009 - 1:55 AM
|
Hello, i habe CExtResizeableDialog with a CExtTabWnd, i have to rsize it to the client with.

If i use the following code: virtual void OnTabWndEraseClientArea( CDC & dc, CRect & rcClient, CRect & rcTabItemsArea, CRect & rcTabNearBorderArea, DWORD dwOrientation, bool bGroupedMode ) { ASSERT_VALID( this ); ASSERT( dc.GetSafeHdc() != NULL ); rcTabItemsArea = rcClient; rcTabItemsArea.DeflateRect(7,0,7,0); PmBridge_GetPM()->PaintTabbedTabClientArea( dc, rcClient, rcTabItemsArea, rcTabNearBorderArea, dwOrientation, bGroupedMode, this ); } it apears like

The Background of the tablist buttons is transparent. Can you tell me the way how to make the left an right buttons non transparent ?
Thanks Dirk Lindner
|
|
|
Technical Support
|
Apr 30, 2009 - 8:37 AM
|
The way of painting tab background demonstrated in your message is incorrect. If you need to implement custom layout inside the tab window, then you should code your version of the CExtTabWnd::_RecalcLayoutImpl() internal virtual method. You can just copy source code from original method and change what you need. The m_rcTabItemsArea rectangle is computed in this method and it defines the area which is occupied by tab items.
|
|
|
Seung Cheol Lee
|
Apr 28, 2009 - 1:19 AM
|
I don’t want to use the auto-hide of CExtControlBar. So I’d like to remove the auto-hide button of CExtControBar. How to do.
|
|
|
Technical Support
|
Apr 28, 2009 - 12:18 PM
|
If you want to disable the auto-hide feature for all control bars in the main frame window, you can do that by commenting out the invocation of CExtControlBar::FrameInjectAutoHideAreas() that is called during main frame initialization. If you want just to remove the auto-hide button from caption(s) of bar(s), you should create and use a CExtControlBar-derived class which implements the CExtControlBar::OnNcAreaButtonsReinitialize() method. Your method should be similar to the original one so you can simply copy code from the original method and just remove the NcButtons_Add( new CExtBarNcAreaButtonAutoHide(this) ); line of code.
|
|
|
Maxim Maximov
|
Apr 22, 2009 - 8:57 AM
|
Hello! I just added CExtToolControlBar to my app, here’s initialization: VERIFY(
g_CmdManager->ProfileSetup(
theApp.m_pszProfileName,
GetSafeHwnd() // HWND of the frame window
)
);
VERIFY(
g_CmdManager->UpdateFromToolBar(
theApp.m_pszProfileName,
IDR_MAINFRAME
)
);
VERIFY(
g_CmdManager->UpdateFromMenu(
theApp.m_pszProfileName,
IDR_MAINFRAME)
);
VERIFY(
g_CmdManager->UpdateFromMenu(
theApp.m_pszProfileName,
IDR_ProfitRangerTYPE)
);
if( !m_wndToolBar.Create(
_T( "Toolbar name" ),
this,
AFX_IDW_TOOLBAR
)
|| !m_wndToolBar.LoadToolBar( IDR_MAINFRAME )
)
{
TRACE0( "Failed to create toolbar" );
return -1;
} Toolbar is displayed, but when I press a button, nothing happens (menu works like a charm).
What is wrong?
|
|
|
Technical Support
|
Apr 22, 2009 - 11:33 AM
|
First of all, please use the CExtControlBar::FrameEnableDocking() static method for enabling redockable bars in your main frame window instead of the MFC’s CFrameWnd::EnableDocking() method. This note is not related to the m_wndToolBar.EnableDocking(CBRS_ALIGN_ANY); line of code. It would be helpful to take a look at entire CMainFrame::OnCreate() method in your project. We suspect the problem can be hidden somewhere else.
|
|
|
Douglas Hoppes
|
Apr 22, 2009 - 7:41 AM
|
In our core library, I am creating a descendant class of CExtGridCellCheckBox and have placed the
IMPLEMENT_SERIAL(CExtGridCellCheckBoxTest, CExtGridCellCheckBox, VERSIONABLE_SCHEMA|1 );
in my cpp file (before my debug statement). The core library builds/links fine. However, when I try to use my core library with my application, I always get the compile error:
"syntax error : identifier ’pMalloc’" in my application (The core library builds fine.... no errors). This is caused by the
IMPLEMENT_ExtGridCell_Clone( CExtGridCellCheckBoxEye, CExtGridCellCheckBox );
How can I get rid of this error?
Note: in my .h file, I have: class MBFCORE_EXT_CLASS CExtGridCellCheckBoxEye : public CExtGridCellCheckBox { public: DECLARE_SERIAL(CExtGridCellCheckBoxTest); IMPLEMENT_ExtGridCell_Clone(CExtGridCellCheckBoxTest, CExtGridCellCheckBox); ...
Doug
|
|
|
Technical Support
|
Apr 22, 2009 - 11:36 AM
|
The IMalloc is a very standard COM interface which is struct type in terms of C++ with only public and virtual methods inside. The CExtAlloc class in Prof-UIS is derived from the IMalloc structure and implements this interface. So, if the IMalloc type declaration is not available when compiling Prof-UIS library and your Prof-UIS based projects, then you should not be able to compile them. But the error described in your message looks like some specific misprint somewhere near the IMPLEMENT_ExtGridCell_Clone line of code and there is not enough information in your message to came to any conclusions about what is really happen. The IMPLEMENT_ExtGridCell_Clone macro function is declared as following:
#define IMPLEMENT_ExtGridCell_Clone( __derived__ , __base__ ) \
virtual CExtGridCell * Clone( \
IMalloc * pMalloc = NULL \
) const \
{ \
ASSERT_VALID( this ); \
if( pMalloc == NULL ) \
return __base__ :: Clone( pMalloc ); \
CExtGridCell * pOther = \
new ( pMalloc, false ) __derived__ \
( ( const_cast \
< __derived__ * > \
( this ) \
) \
-> DataProviderGet() \
); \
ASSERT( pOther != NULL ); \
if( pOther != NULL ) \
{ \
ASSERT_VALID( pOther ); \
pOther->Assign( *this ); \
ASSERT( pOther->DataProviderGet() == DataProviderGet() ); \
} \
return pOther; \
}
As you can see there are no any other specific macros inside it which can be occasionally redefined in scope of your project. It contains only enough simple lines of code and one invocation of the new operator with custom parameters. This operator is provided by the CExtGridCell class and it’s automatically available for all the grid cell classes. Could you please send us a smallest possible test project which has the same compilation error?
|
|
|
Takis Takoglou
|
Apr 22, 2009 - 7:40 AM
|
Good day, I am using the ExpandedSet(false) method to make a Category in my PropertyGrid appear collapsed. While this works fine under most circumstances, when i insert into this category another one which is not collapsed, the program crashes. To make things clear:
CExtPropertyCategory *Child = new CExtPropertyCategory();//Create a sub-category
Child->ItemInsert(aValue);//Add a value in it
CExtPropertyCategory *Parent = new CExtPropertyCategory();//Create the "root" category
Parent->ExpandedSet(false);//And set it to appear collapsed
Parent->ItemInsert(Child);//Insert the child into the parent
PropStore.ItemInsert(Parent);//Insert Parent in Property Store
GridCtrl.PropertyStoreSynchronize();//****HERE THE PROGRAM CRASHES***// Note that if the child is also collapsed, this doesn’t happen... Also if "Ignore" is pressed, the Property grid is displayed correctly i.e. Parent collapsed with child expanded. How can i overcome this problem? Thanx in advance, Stakon.
|
|
|
Technical Support
|
Apr 22, 2009 - 11:34 AM
|
There are the following lines of code in the PropertyGrid sample application:
CExtPropertyCategory * pCategoryAppearance =
new CExtPropertyCategory( _T("Appearance") );
//pCategoryAppearance->ExpandedSet( false );
The Appearance category has some subcategorizes. If we uncomment the last line, then the Appearance category will appear collapsed when it has expanded children. There are several unwanted assertions in Prof-UIS 2.84 in this case. But there are no crashes/assertions occur in Prof-UIS 2.85. We suspect the several tree grid improvements we did affected to this issue. We can provide you with the source code update.
|
|
|
Takis Takoglou
|
Apr 23, 2009 - 12:24 AM
|
Yes , please It would be nice to have the updated code.
You can send it at my registered email address. Thanx in advance,
Stakon.
|
|
|
Technical Support
|
Apr 23, 2009 - 12:44 PM
|
Do you have any company e-mail? We need to send you the FTP download information and we would prefer not to send such login information to mail boxes on public mail servers.
|
|
|
Takis Takoglou
|
Apr 23, 2009 - 4:36 AM
|
Today some new problems rose while using the Property Grid. In particular I am using a PropertyGrid which contains many cells, so the vertical scrollbar is enabled.
When i add a new item (i.e. a value cell) in the grid by pressing a button in the same grid and then use grid.PropertyStoreSnchronize()
the view resets to the top tree node and the scrollbar moves in the uppermost position. This behavior isn’t user friendly.
I would like to find a way so that the view doesn’t change once i synchronize the PropertyStore, but stays in the same position (i.e. the button just pressed).
Note that if i simply change a value of another cell which is out of view and synchronize, the view does not change. This only happens if i add a new item in the grid and then synchronize.
Also note that i have tried to use grid.PropertyStoreSet(pPropStore) and the view is not reset to the top node but it does change a bit.
Thanx in advance,
Stakon.
|
|
|
Technical Support
|
Apr 27, 2009 - 11:05 AM
|
This is a known issue. The CExtPropertyGridCtrl::PropertyStoreSynchronize() completely removes all the grid cells, tree rows and columns in all the tree grids inside the property grid control. Then this method initializes new content inside the tree grid windows. I.e. this method completely reinitializes the tree grids. Modifying property store structure on the fly is not an ordinal task. The property grid control cannot detect how serious are property tree structure modifications and simply reinitializes tree grids. You can insert all the possible property values and categories into your property store’s tree and make un-available property values read-only.
|
|
|
Takis Takoglou
|
Apr 22, 2009 - 8:08 AM
|
If this helps , the error produced is Debug Assertion Failed
in File ExtGridWnd.cpp Line 6310.
|
|
|
Takis Takoglou
|
Apr 21, 2009 - 7:44 AM
|
Good day, I am using your property grid and used a custom button within my grid using the OnButtonPressed() this way:
IMPLEMENT_SERIAL(ExtraProperties, PropertyValue, VERSIONABLE_SCHEMA|1 );
ExtraProperties::ExtraProperties(MyProperty *pProp)
: PropertyValue(_T("More"), pProp)
{
CustomButt *pValue = STATIC_DOWNCAST(CustomButt, ValueActiveGetByRTC( RUNTIME_CLASS(CustomButt)));
pValue->TextSet("......");
pValue->ParentSet(this); //When this is initialized pValue->ParentProps is filled!
ValueDefaultFromActive();
}
void ExtraProperties::Apply(CExtGridCell * pValue)
{
PropertyValue::Apply( pValue );
}MPLEMENT_SERIAL(CustomButt, CExtGridCellButton, VERSIONABLE_SCHEMA|1 );
CustomButt::CustomButt(CExtGridDataProvider * pDataProvider // = NULL
)
: CExtGridCellButton( pDataProvider )
{
ModifyStyle( __EGCS_BUTTON_ELLIPSIS | __EGCS_NO_INPLACE_CONTROL, 0 );
}
void CustomButt::OnButtonPressed(CExtGridWnd & wndGrid, INT nButtonType,
const RECT & rcCellExtra, const RECT & rcCell, LONG nVisibleColNo, LONG nVisibleRowNo,
LONG nColNo, LONG nRowNo, INT nColType, INT nRowType)
{
ASSERT_VALID( this );
ASSERT_VALID( (&wndGrid) );
CExtGridCellButton::OnButtonPressed(wndGrid, nButtonType,
rcCellExtra, rcCell, nVisibleColNo, nVisibleRowNo, nColNo, nRowNo,
nColType, nRowType);
this->ParentProps;//This should be the pointer to the PropertyValue but is NULL...
}
void CustomButt::ParentSet(ExtraProperties *par)
{
this->ParentProps = par;
}I have highlited the problem. I was expecting to find the pointer to the "parent" so i could use something like : Propstore.ItemGetByName("Button1") or Propstore.ItemGetByName("Button2") etc. depending on which button i want to refer to was pressed. Why is this happening? Is there any other way to overcome this? (Refere to the parent within the OnButtonPressed implementation) Thanx in advance, Stakon.
|
|
|
Technical Support
|
Apr 22, 2009 - 11:34 AM
|
The CustomButt grid cell class should have the IMPLEMENT_ExtGridCell_Clone macro in class declaration. Please read this: http://www.prof-uis.com/prof-uis/tech-support/feature-articles/prof-uis-grid-brief-overview.aspx There is an example of grid cell code in this article (CMyCustomCell). Please note IMPLEMENT_DYNCREATE line should be placed at the very beginning of the CPP file before the debug version of MFC’s new operator. The CustomButt class should implement the CExtGridCell::Assign() virtual method which should detect whether the assignment query is from the grid cell of the same CustomButt type and assign it’s specific properties. For example, this is how the CExtGridCellHyperLink class in Prof-UIS implements this virtual method:
void CExtGridCellHyperLink::Assign( const CExtGridCell & other )
{
ASSERT_VALID( this );
CExtGridCellString::Assign( other );
CExtGridCellHyperLink * pCell = DYNAMIC_DOWNCAST( CExtGridCellHyperLink, ( const_cast < CExtGridCell * > ( &other ) ) );
if( pCell != NULL )
{
// copy cell
m_clrTextVisited = pCell->GetTextColorVisited();
m_bHoverTextUnderline = pCell->GetTextHoverUnderline();
m_bAllowVisitedState = pCell->GetAllowVisitedState();
m_strURL = pCell->GetURL();
} // if( pCell != NULL )
else
{
// clear cell
m_clrTextVisited = RGB( 128, 0, 128 );
m_bHoverTextUnderline = FALSE;
m_bAllowVisitedState = TRUE;
m_strURL = _T("");
} // else if( pCell != NULL )
}
|
|
|
L Freddi
|
Apr 16, 2009 - 7:42 PM
|
Hi, I have a dialog inherited CExtResizableDialog dialog in window inherited CExcontrolBar. I want to add scrollbar in dialog and use scrollbar when the dialog is resizing. I add WS_HSCROLL property in creating window but scroll is not shown. Please help me. ====================================================================== CExtResizableDialog clsDlg; CExcontrolBar clsDlgWnd; if (!clsDlgWnd.Create(_T("Dialog"),
this,
ID_VIEW_PANEL_PTZ,
WS_CHILD|WS_VISIBLE | WS_HSCROLL
|CBRS_LEFT|CBRS_GRIPPER|CBRS_TOOLTIPS |CBRS_FLYBY|CBRS_SIZE_DYNAMIC
|CBRS_HIDE_INPLACE))
{
return FALSE;
} if (!clsDlg.Create(IDD_DIALOG, &m_clsWnd))
{
return FALSE;
}
===========================================================================
|
|
|
Technical Support
|
Apr 17, 2009 - 10:14 AM
|
You can create a CExtScrollContainerWnd window as a child of the CExtControlBar window, then create your dialog window as a child of the CExtScrollContainerWnd window.
|
|
|
Oliver Rau
|
Apr 15, 2009 - 9:27 AM
|
Dear ProfUIS-Team,
what would be the right way to serialize keyboard shortcuts that have been defined or modified through CExtCustomizePageKeyboard not in the registry but in a file?
Kind regards,
Martin
|
|
|
Technical Support
|
Apr 16, 2009 - 1:55 PM
|
The keyboard shortcuts are serialized as part of the customization subsystem state. The CExtCustomizeSite::CustomizeStateSerialize() method allows you to serialize the state of the customization subsystem into the CArchive stream which can be based on the CFile object opened on the file system’s file. If you need to serialize keyboard accelerators only, the following code does this for all the registered documents/menus: CArchive & ar = . . .
CExtCustomizeSize * pSite = . . .
INT i, nMenuInfoCount = pSite->MenuInfoGetCount();
for(i = 0; i < nMenuInfoCount; i++ )
{
CExtCustomizeSize::CCmdMenuInfo * pCmdMenuInfo = pSite->MenuInfoGetAt( i );
ASSERT( pCmdMenuInfo != NULL );
pCmdMenuInfo->AccelTableSerialize( ar );
}
You can serialize the keyboard accelerators of one menu line only by invoking its CExtCustomizeSite::CCmdMenuInfo::AccelTableSerialize() method. You should invoke the CExtCustomizeSite::OnUpdateAccelGlobalInfo() method after loading keyboard accelerators.
|
|
|
Douglas Hoppes
|
Apr 14, 2009 - 2:11 PM
|
Hi all,
Is there a way to create a swappable image in a grid cell? In the grid cell, I would like to have an Eye icon showing. When the user clicks on the image, a blank image will be shown. The primary example of this is like Photoshop (or any other graphics tool). When the user clicks on the Eye Icon in their list, the image is hidden. If the blank area is clicked on, the image is shown and the Eye icon is displayed again.
Doug
|
|
|
Douglas Hoppes
|
Apr 15, 2009 - 12:09 PM
|
Thanks for the response. The look/feel is exactly what I was looking for. However, I’m running into an issue with it.
In our core library, I have a special class called CGridControl. This is a wrapper class surrounding all of the Prof-UI grid functionality. In this library goes the CExtGridCellCheckBoxEye.
Now, my application links to this core library, I always get the compile error: "syntax error : identifier ’pMalloc’" in my application (The core library builds fine.... no errors). This is caused by the
IMPLEMENT_ExtGridCell_Clone( CExtGridCellCheckBoxEye, CExtGridCellCheckBox );
How can I get rid of this error?
Doug
|
|
|
Technical Support
|
Apr 16, 2009 - 1:51 PM
|
You inserted declaration of the CExtGridCellCheckBoxEye class into some .h file in your project. The next step is to insert the following line of code into some .cpp file: IMPLEMENT_SERIAL( CExtGridCellCheckBoxEye, CExtGridCellCheckBox, VERSIONABLE_SCHEMA|1 );
This line should be inserted at the very beginning of the code file and before declaration of the debug new operator: #ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
|
|
|
Douglas Hoppes
|
Apr 17, 2009 - 8:20 AM
|
I already had. From the zip file, I had split the code from the .h to the .h/.cpp.
So, my .h looks like: --------------------------------------------------------------------------------- class CExtGridCellCheckBoxEye : public CExtGridCellCheckBox { public: DECLARE_SERIAL(CExtGridCellCheckBoxEye); IMPLEMENT_ExtGridCell_Clone(CExtGridCellCheckBoxEye, CExtGridCellCheckBox); CExtSafeString m_arrStrings[3]; // 0 - unchecked, 1 - checked, 2 - indeterminate mutable CExtCmdIcon m_arrIcons[3]; // 0 - unchecked, 1 - checked, 2 - indeterminate CExtGridCellCheckBoxEye(CExtGridDataProvider *pDataProvider = NULL); virtual __EXT_MFC_SAFE_LPCTSTR GetTextBuffer() const; protected: INT _GetTextAndCheckMarkIconIndex() const; public: virtual void TextGet( CExtSafeString & strCopy ) const; virtual void Assign( const CExtGridCell & other ); virtual void Serialize( CArchive & ar ); virtual CSize OnCalcCheckSize( bool bPressed, bool bHovered, bool bEnabled, const CExtGridWnd & wndGrid, CDC & dc, LONG nVisibleColNo, LONG nVisibleRowNo, LONG nColNo, LONG nRowNo, INT nColType, INT nRowType, DWORD dwAreaFlags, DWORD dwHelperPaintFlags ) const; virtual void OnPaintCheck( const RECT & rcCheck, bool bPressed, bool bHovered, bool bEnabled, const CExtGridWnd & wndGrid, CDC & dc, LONG nVisibleColNo, LONG nVisibleRowNo, LONG nColNo, LONG nRowNo, INT nColType, INT nRowType, const RECT & rcCellExtra, const RECT & rcCell, const RECT & rcVisibleRange, DWORD dwAreaFlags, DWORD dwHelperPaintFlags ) const; }; -----------------------------------------------------------------
.cpp looks like (I took out the code to make it easier to read) ----------------------------------------------------------------- CExtGridCellCheckBoxEye::CExtGridCellCheckBoxEye(CExtGridDataProvider * pDataProvider /* = NULL */) :CExtGridCellCheckBox ( pDataProvider ) { }
__EXT_MFC_SAFE_LPCTSTR CExtGridCellCheckBoxEye::GetTextBuffer() const { }
INT CExtGridCellCheckBoxEye::_GetTextAndCheckMarkIconIndex() const { }
void CExtGridCellCheckBoxEye::TextGet(CExtSafeString &strCopy) const { }
void CExtGridCellCheckBoxEye::Assign(const CExtGridCell &other) { }
void CExtGridCellCheckBoxEye::Serialize(CArchive &ar) { }
CSize CExtGridCellCheckBoxEye::OnCalcCheckSize(bool bPressed, bool bHovered, bool bEnabled, const CExtGridWnd &wndGrid, CDC &dc, LONG nVisibleColNo, LONG nVisibleRowNo, LONG nColNo, LONG nRowNo, INT nColType, INT nRowType, DWORD dwAreaFlags, DWORD dwHelperPaintFlags) const { }
void CExtGridCellCheckBoxEye::OnPaintCheck(const RECT &rcCheck, bool bPressed, bool bHovered, bool bEnabled, const CExtGridWnd &wndGrid, CDC &dc, LONG nVisibleColNo, LONG nVisibleRowNo, LONG nColNo, LONG nRowNo, INT nColType, INT nRowType, const RECT & rcCellExtra, const RECT &rcCell, const RECT &rcVisibleRange, DWORD dwAreaFlags, DWORD dwHelperPaintFlags) const { }
|
|
|
Douglas Hoppes
|
Apr 17, 2009 - 8:21 AM
|
Whoops... Forgot.. at the top of my cpp file, I had:
IMPLEMENT_SERIAL(CExtGridCellCheckBoxEye, CExtGridCellCheckBox, VERSIONABLE_SCHEMA|1 );
#ifdef _DEBUG #define new DEBUG_NEW #endif
|
|
|
Technical Support
|
Apr 15, 2009 - 4:19 AM
|
Please download the following ZIP file:
http://www.prof-uis.com/download/forums/tmp/ProfUIS_Controls_PageGrid_UpdatedFiles.zip
Then please unpack the PageGrid.cpp and PageGrid.h files from it into the ..\Prof-UIS\Samples\ProfUIS_Controls folder. Then compile and run the ProfUIS_Controls sample application and select the Grid dialog page. The second column from the left side in the grid window has the CheckBox caption and contains two check box cells with the hidden/visible/semi-transparent eye instead of the check mark. These check box cells are instances of the CExtGridCellCheckBoxEye class which is inside the updated PageGrid.cpp and PageGrid.h files.
|
|
|
Douglas Hoppes
|
Apr 15, 2009 - 1:09 PM
|
Thanks for the response. The look/feel is exactly what I was looking for. However, I’m running into an issue with it.
In our core library, I have a special class called CGridControl. This is a wrapper class surrounding all of the Prof-UI grid functionality. In this library goes the CExtGridCellCheckBoxEye.
Now, my application links to this core library, I always get the compile error: "syntax error : identifier ’pMalloc’" in my application (The core library builds fine.... no errors). This is caused by the
IMPLEMENT_ExtGridCell_Clone( CExtGridCellCheckBoxEye, CExtGridCellCheckBox );
How can I get rid of this error?
Doug
|
|
|
L Freddi
|
Apr 13, 2009 - 7:31 PM
|
Hi, I have tabbed pages int tab container. I want to float a tab in tabbed pages. Give a solution, please. thanks.
|
|
|
Technical Support
|
Apr 14, 2009 - 11:36 AM
|
The CExtTabPageContainer control does not support floating page windows. It supports only child window pages. You should use control bars docked into a tabbed container. You can also choose on using dynamic control bars demonstrated in the SDI_DynamicBars and MDI_DynamicBars sample applications. The dynamic bars can be switched into the persistently floating state.
|
|
|
Sebstian Leopold
|
Apr 10, 2009 - 8:30 PM
|
Hello, I have a problem with the layout of the ribbonbar after a window state change from maximized to normal window. If there is enough space (width) in the normal window the groups in a tab page are not correctly placed after a state change.
I can also reproduce this bug in your ribbonbar sample application doing the following steps:
1. Use a Desktop with a large resolution like (1650 x XXXX) 2. Now resize the window to a size where all groups are shown in maximal layout. 3. Now double click on the caption to maximize the window. 4. Double click the caption again and you will see the error in the ribbon bar.
If the window is smaller (step 2) so that the bar has to shrink the items in it,, the problem doesn’t occur.
regards S. Leopold
|
|
|
Technical Support
|
Apr 13, 2009 - 1:18 PM
|
Thank you for reporting this issue. We fixed it by adding the WM_WINDOWPOSCHANGED case to the following method:
LRESULT CExtRibbonPage::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
{
__PROF_UIS_MANAGE_STATE;
switch( message )
{
case WM_WINDOWPOSCHANGED:
m_bRibbonSimplifiedLayoutDelayedFlush = true;
break;
case WM_DESTROY:
if( m_hWndParentRibbonPage != NULL
&& ( ::IsWindow( m_hWndParentRibbonPage ) )
)
{
::InvalidateRect( m_hWndParentRibbonPage, NULL, TRUE );
if( m_bHelperAutoHideMode )
_CloseTrackingMenus();
}
break;
default:
if( message == g_nMsgSyncAccelTable )
{
if( ! m_bHelperPopupMode )
OnUpdateAccelGlobalInfo( false );
return 0L;
} // if( nMessage == g_nMsgSyncAccelTable )
else if( message == g_PaintManager.m_nMsgPaintManagerChanged )
{
MSG _msg;
while(
::PeekMessage(
&_msg,
m_hWnd,
g_PaintManager.m_nMsgPaintManagerChanged,
g_PaintManager.m_nMsgPaintManagerChanged,
PM_REMOVE
)
);
PmBridge_OnPaintManagerChanged( PmBridge_GetPM() );
return 0L;
} // else if( message == g_PaintManager.m_nMsgPaintManagerChanged )
break;
} // switch( message )
LRESULT lResult = CExtMenuControlBar::WindowProc( message, wParam, lParam );
return lResult;
}
|
|
|
Sebstian Leopold
|
Apr 10, 2009 - 8:45 PM
|
System: Windows Vista Home Premium 32 Bit
|
|