Subject |
Author |
Date |
|
Eddie Judson
|
Aug 31, 2005 - 6:57 AM
|
Is there any way of stopping the pages in the PageNavigator from collapsing into small icons at the bottom? Or alternatively setting the height of the splitter?<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p> Regards,<o:p></o:p> Eddie
|
|
Technical Support
|
Aug 31, 2005 - 9:02 AM
|
You can simply remove the splitter if you override the CExtPageNavigatorWnd::OnQuerySplitterHeight() virtual method in a CExtPageNavigatorWnd -derived class and return zero in it: INT CMyPageNavigatorWnd::OnQuerySplitterHeight() const
{
ASSERT_VALID( this );
return 0;
} It seems we need to add the corresponding flag to control the splitter visibility. So, we added this request to our TODO list.
|
|
Bob Sabiston
|
Aug 30, 2005 - 6:40 PM
|
Hi: I’d like to have the cabability of showing / hiding the mdi tab bar when using a CExtTabMdiWnd. The tab bar would be hidden in two cases: 1) Only one document is open. In this case, it would look like an SDI application. 2) In full screen mode. One possibility that would work would be similar to the CManagedTabPageContainer in the TabPages example. I could override the OnFlatTabWndGetSize function to return 0 when I want to hide the tabs. There are twp problems with this: - I don’t have the flexibility of using other styles of windows like CExtTabMdiOneNoteWnd (for example) - It just seems liike this should be easier! Thanks, Bob Sabiston
|
|
Technical Support
|
Aug 31, 2005 - 7:04 AM
|
The visibility of the mdi tab window is managed automatically by the CExtTabMdiWnd::OnTabWndSyncVisibility virtual method. So, just override this method in a CExtTabMdiWnd -derived class like as follows: class CMyExtTabMdiWnd : public CExtTabMdiOneNoteWnd
{
public:
CMyExtTabMdiWnd()
: CExtTabMdiOneNoteWnd()
, m_bVisible( true )
{
}
void SetVisibility(bool bVisible=true)
{
m_bVisible = bVisible;
}
bool GetVisibility()
{
return m_bVisible;
}
protected:
bool m_bVisible;
virtual void OnTabWndSyncVisibility ()
{
ShowWindow(
m_bVisible && ItemGetCount() > 0
? SW_SHOW
: SW_HIDE
);
}
}; // class CMyExtTabMdiWnd After calling the CMyExtTabMdiWnd::SetVisibility method, do not forget to call the RecalcLayout method of the frame window.
|
|
Courtney Smith
|
Aug 30, 2005 - 10:26 AM
|
I have tried creating a new application with the prof-uis wizard. Didn’t work. I got a bunch of linking errors. I set the paths and variables like the Getting Started article said to. I went back to the paths and variables and with a purchased version it said trail after prof-uis. So I removed it and then recompiled then i get an error that the dll file is missing. Can anyone please help.
|
|
Technical Support
|
Aug 30, 2005 - 1:01 PM
|
It seems the web conference we just held asked all your questions. Please do not hesitate to contact us if you have any questions.
|
|
Srinivasan Natarajan
|
Aug 30, 2005 - 5:05 AM
|
Hi, We would like to know whether CExtGridWnd supports tree like display (Grouping) . In the support forum, i found that this feature would be added in the month of April , but i am not sure whether it is available. If so, then please send me sample code ASAP. regards sundar
|
|
Technical Support
|
Aug 30, 2005 - 7:31 AM
|
We are working on the report grid and it will be available in one of the next releases.
|
|
Srinivasan Natarajan
|
Aug 31, 2005 - 11:10 PM
|
By the way, when it is expected to get released ? regards sundar
|
|
Technical Support
|
Sep 1, 2005 - 11:28 AM
|
The next major release will be available within the next two weeks. The report grid control will be released in 3-4 weeks.
|
|
Srinivasan Natarajan
|
Sep 14, 2005 - 1:05 AM
|
Thanks for the reply. We are eagerly waiting for the Grid Control. If you can release this control in the current version itself it would be really helpful for us since our project is waiting for the treeview control. thanks & regards sundar
|
|
David Baginski
|
Aug 26, 2005 - 2:44 PM
|
Any plans to offer a CExtEdit control that can be used with multi-line edit fields?
|
|
Technical Support
|
Aug 27, 2005 - 8:20 AM
|
There is a conflict between the CExtEdit class and the multiline edit common control. The CExtEdit class uses the non-client area to draw the theme-based border. The edit common control uses the non-client area to draw scroll bars of the multiline edit control. You can use the CExtEditBase class instead. It implements all the features but the border painting. The CExtEditBase class displays the Prof-UIS menu over the edit control and performs z-order adjustment of the tool tip window. You can create a CExtEditBase window without any default Windows theme border. The border can be implemented in the editor’s parent window (e.g., the CProfStudioThinFrame window in the ProfStudio sample application).
|
|
David Baginski
|
Aug 29, 2005 - 12:04 PM
|
How do you create the CExtEditBase window without any default Windows theme border?
Also, when I use the backspace key, the carrot moves but the last characters are not deleted. Can this be fixed easily as well?
|
|
Technical Support
|
Aug 30, 2005 - 5:46 AM
|
We are sorry for misleading you. In fact, CExtEdit should support the multiline mode. We fixed this bug several versions ago. Just turn on the multiline option in the resource editor. As for the problem with not deleting the last characters when using the backspace key, it was fixed in Prof-UIS 2.42.
|
|
Krustys Donuts
|
Aug 25, 2005 - 6:07 PM
|
I really need to be able to add a sub category to another category, but would like Prof-UIS to honor the nIndexInsertBefore parameter. Currently, regardless of the index specified, the sub-category always appears in the first row below the main category. I actually need it to appear dynamically below a property value if its checkbox is checked. Thanks!
|
|
Technical Support
|
Aug 26, 2005 - 12:18 PM
|
The categorized property grid window is implemented in the the CExtPropertyGridWndCategorized class. Jus find this window in the CExtPropertyGridCtrl container window with the CExtPropertyGridCtrl::GetChildByRTC() method and set the m_bSortedCategories property of the categorized grid to false . This will allow the categories to be added as you request.
|
|
Krustys Donuts
|
Aug 26, 2005 - 12:47 PM
|
Wonderful! That totally works. Now, I just have an issue with deleting the category. I figured that if the category and its values are inserted at index X, when I want to remove the category and its value, I just call ItemRemove( X, 1).
However, when I do this, the application crashes at CExtPropertyGridWnd::PropertyItemFromTreeItem on ASSERT_VALID( pPropertyItem );
If I look at the line that caused the crash, it’s in ExtPropertyGridWnd.cpp on line 3598. Any ideas on what’s causing this?
|
|
Technical Support
|
Aug 26, 2005 - 1:07 PM
|
Please use one of the CExtPropertyGridWnd::PropertyItemRemove() overloaded methods to remove a property item from the particular grid window. This will allow you to avoid problems with an internal map object for mapping the CExtPropertyValue pointer to the HTREEITEM handle and vice versa. The property grid control synchronization with the CExtPropertyGridCtrl::PropertyStoreSynchronize() is a safe and painless way to make property grid windows inside the property grid control synchronized with values in the original property tree.
|
|
Krustys Donuts
|
Aug 29, 2005 - 8:15 AM
|
Thanks, that works fine, but now it crashes if I show the category, hide it, and then show it again. So I changed my code to use PropertyItemInsert instead of calling ItemInsert directly. However, when I do this and add the category dynamically nothing really happens. I can see the scrollbar update, but the contents of the main category remain the same. My code snippet looks like this in my property grid subclass:
GetActiveGrid()->PropertyItemInsert( pCategory); // pCategory is the subcategory I want to add at runtime
PropertyStoreSynchronize();
|
|
Krustys Donuts
|
Aug 29, 2005 - 8:30 AM
|
Correction to the above: I shouldn’t call PropertyItemInsert anyway, because I want to add a subcategory, and not a category. So it seems that I’d have to call the main category’s ItemInsert to get the subcategory (just like in your sample application).
Therefore, my only question is, why does my application crash when I add, remove, and then add the category again? When reproducing this problem, please add with ItemInsert, and remove with PropertyItemRemove.
Thank you!
|
|
Krustys Donuts
|
Aug 29, 2005 - 8:44 AM
|
If I set the insertion index to 0, then I can add, remove, and add again. However, the weird thing here is that when I re-add the sub-category, a duplicate is displayed as if the previous one wasn’t ever removed.
If I set the index back to what I used before (7), my application gives me the following error as soon as I call ItemInsert the second time:
Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared with one calling convention with a function pointer declared with a different calling convention.
This happens on line 631 in ExtTreeGridWnd.cpp.
Thanks again!
|
|
Technical Support
|
Aug 29, 2005 - 10:46 AM
|
We may guess this is a result of inserting a property item which is not part of a property store currently used in the property grid control. If not, then we need your help in reproducing this problem. Could you send us your project or modified version of the PropertyGrid sample application? Alternatively, we could set up a web conference with secure remote access to your desktop.
|
|
Krustys Donuts
|
Aug 30, 2005 - 7:47 AM
|
Hello again, I’ve attached my application to an email to support@prof-uis.com. Please be sure to try a couple of different values for the index variable in CMyGrid::showSpecialProperties(). When index == 0, I can show and hide the subcategory a couple of times, but the second time I add the category, two copies show up, even though I deleted the previous one (supposedly). If I try to show a third time, the program crashes. When index == 2, I can show and hide only *once*, and the second time I try to show the subcategory, I get the stack corruption (?) message.
Also, I have a comment in stdafx regarding the specification of the prof-uis dll. I was previously told that this is unnecessary, but I can’t get the project to link without it. Can you please help me with that as well?
Thank you!
|
|
Technical Support
|
Aug 30, 2005 - 1:07 PM
|
We received your e-mail with the attached project. We will try to find a solution within 12 hours.
|
|
Krustys Donuts
|
Aug 30, 2005 - 1:23 PM
|
Hi, I received an email from you already -- should I still be expecting a solution? I was asked for more details about my application. Basically, I just want to dynamically add subcategories based on a user clicking various checkboxes.
|
|
Technical Support
|
Aug 31, 2005 - 10:35 AM
|
We it’s completely clear what you need exactly. Please give us 3-4 days for providing you with a ready-to-use solution.
|
|
Krustys Donuts
|
Sep 6, 2005 - 5:10 PM
|
|
|
Technical Support
|
Sep 7, 2005 - 12:49 PM
|
We have deadlines for implementing compound property values and this propblem. In any case, we will not release the next version until the problem with adding/removing the property value dynamically is resolved. Please let us know how much time we have additionally.
|
|
Krustys Donuts
|
Oct 10, 2005 - 7:44 AM
|
I’ve come back to a previous project where I needed to dynamically display properties if a checkbox in another property is checked. When testing under 2.43, my application still crashes. Do you have sample code that I can look at that demostrates this capability? It’s been about a month since my previous request.
|
|
Technical Support
|
Oct 10, 2005 - 10:41 AM
|
We’ve just sent a project that seems to be what you need by e-mail.
|
|
Krustys Donuts
|
Sep 8, 2005 - 4:35 PM
|
Well, I’d like to have this functionality today, but I understand that it’s not possible. Hopefully, you can have it fixed within a couple of weeks, though.
|
|
Krustys Donuts
|
Aug 25, 2005 - 4:02 PM
|
Hi, I have a CExtGridCellString, and want to dynamically change its text. I got a pointer to the cell using ValueActiveGet(), and then set the text using TextSet(). However, the text doesn’t update! I am wondering if I’m supposed to explicitly redraw the window, and if so, what method do I call?
|
|
Technical Support
|
Aug 26, 2005 - 6:47 AM
|
You need to explicitly redraw the property grid window when you change cell values programmatically: m_PGC.OnSwUpdateScrollBars();
m_PGC.OnSwDoRedraw();
|
|
Krustys Donuts
|
Aug 26, 2005 - 7:05 AM
|
Hi, thanks... just to clarify for other here, the actual call from a property grid ctrl subclass is:
GetActiveGrid()->OnSwUpdateScrollBars();
GetActiveGrid()->OnSwDoRedraw();
However, for some reason, this still doesn’t work. Here’s what my code snippet looks like:
CExtPropertyCategory* pCategory = static_cast<CExtPropertyCategory*>(store.ItemGetAt( 0));
int numProperties = pCategory->ItemGetCount();
for( int i=0; i<numProperties; i++) {
CExtPropertyItem* pItem = pCategory->ItemGetAt( i);
string name = pItem->NameGet();
if( name != "donut with sprinkles")
continue;
CExtGridCellString* pCell = dynamic_cast<CExtGridCellString*>(pItem->ValueActiveGet());
pCell->TextSet( editboxes[name].c_str()); // the editboxes[name] is just a dynamically generated name
}
GetActiveGrid()->OnSwUpdateScrollBars();
GetActiveGrid()->OnSwDoRedraw();
The autogenerated text is correct when looking at the watch variable. After the calls to OnSw...(), the text still doesn’t update!
|
|
Technical Support
|
Aug 26, 2005 - 1:02 PM
|
The CExtPropertyValue class contains two CExtGridCell objects describing the active and default values of a property. Your code gets a pointer to the active value cell and changes it absolutely correctly. But the grid windows inside the property grid control contains copies of the grid cell objects being modified by your code and the property grid control needs to be synchronized with the CExtPropertyGridCtrl::PropertyStoreSynchronize() method. Alternatively you can traverse all the grid windows inside the property grid control, find the cell objects corresponding to the property value and modify them: CExtPropertyGridCtrl & _PGC = . . .
CExtPropertyValue * pValue = . . .
CTypedPtrArray < CPtrArray, CExtPropertyGridWnd * > arrGrids;
_PGC.OnPgcQueryGrids( arrGrids );
INT nGridIdx = 0;
for( ; nGridIdx < arrGrids.GetSize(); nGridIdx ++ )
{
CExtPropertyGridWnd * pGrid = arrGrids[ nGridIdx ];
ASSERT_VALID( pGrid );
HTREEITEM hTreeItem =
pGrid->PropertyItemToTreeItem( pValue );
if( hTreeItem == NULL )
continue;
CExtGridCell * pCell =
pGrid->ItemGetCell( hTreeItem, 1 );
if( pCell == NULL )
continue;
ASSERT_VALID( pCell );
pCell->TextSet( . . . );
// REDRAW MODIFIED CELL ONLY:
if( (pGrid->GetStyle()&WS_VISIBLE) == 0 )
continue;
LONG nPlainIndex =
pGrid->ItemGetVisibleIndexOf( hTreeItem );
if( nPlainIndex < 0 )
continue;
CRect rc;
pGrid->GridCellRectsGet(
1, nPlainIndex, 0, 0, NULL, &rc );
pGrid->InvalidateRect( &rc );
pGrid->UpdateWindow();
} // for( ; nGridIdx < arrGrids.GetSize(); nGridIdx ++ )
|
|
Chris Thomas
|
Aug 25, 2005 - 1:32 PM
|
Hello, I’m trying to modify the page container sample to support drag&drop captions. I’d like to be able to re-order the captions. Do you have some code for this, or could you point me at something I could base it on?
I’d really like to be able to drag&drop CDialogs, from CExtControlBar parents, into pages in a page container window, and drag&drop pages out to become floating bars again. But I have no idea how to make it interact with the rest of the docking system.
|
|
Technical Support
|
Aug 26, 2005 - 12:13 PM
|
The CExtPageContainerWnd window does not implement a ready-to-use drag-and-drop algorithm but it has a built-in ability to detect when drag-and-drop starts when the user clicks a caption item and moves the mouse a bit. This is demonstrated in the PageContainer sample application. If you select the allow start drag-n-drop captions check box in the main view window and try to drag-and-drop the page caption, you will see the event notification message box. To enable drag-and-drop detection, please apply the __EPCWS_CAPTION_DRAG style with the CExtPageContainerWnd::ModifyPageContainerStyle() method and override the CExtPageContainerWnd::OnPageContainerStartCaptionDrag() virtual method as it is shown in the CDemoPageContainerWnd class of the PageContainer sample. The page container window has nothing to do with the resizable control bar implemented in the CExtControlBar class. To drag-and-drop pages is specific for each particular application. We are ready to discuss details of what you need to implement and provide you with advice or a ready-to-use solution.
|
|
David Coleman
|
Aug 24, 2005 - 4:17 PM
|
Hello, I have a weird situation in my application where selecting a certain menu item causes the application to crash when then associated dialog box is displayed! Strangely calling the same dialog box from the toolbar works perfectly! The crash also only happens on some computers and not others - it works fine on mine, but not my colleagues! This bug has only started happening since v2.33 - I am currently using v2.42. The OS is Windows XP if it helps. Any ideas? David.
|
|
Technical Support
|
Aug 25, 2005 - 6:44 AM
|
Please tell whether this problem can be reproduced in any if the Prof-UIS samples? Could you formulate any difference between your dialog and simple About box dialog? Does your application perform some background actions during idle time processing or by timer? Does this problem appear in the release build only? Of course, if you send us a test project, that would be of great help to pinpoint and fix the problem quickly.
|
|
David Coleman
|
Aug 25, 2005 - 8:14 AM
|
I found a solution which works but it is very odd!!! Just out of curiousity I swapped the order of the menu items. It was originally Fetch, Delete, and Scheduler, which I changed to Fetch, Scheduler, and Delete. There is now absolutely no crashing whatsover - work that out!!! I would say that this strongly points to a bug in Prof-Uis... David.
|
|
Technical Support
|
Aug 26, 2005 - 12:01 PM
|
We have never encountered this bug and we never received information about it from library users. We would greatly appreciate if you let us a chance to find it in your application or in Prof-UIS. Unfortunately you did not answer our questions in our previous message in this thread.
|
|
Krustys Donuts
|
Aug 24, 2005 - 8:07 AM
|
Hi, it doesn’t look like the PropertyGridCtrl is sorting correctly. If you select the category view, the underlying values are sorted alphabetically (which we don’t want to do). If we select the alphabetical view, the values are displayed in the order that they are added to the category.
If you run your PropertyGrid sample, you’ll notice two things: 1) the category view is sorted (which may not mean anything because you could have just added the items alphabetically), and 2) the alphabetical view sorts correctly, but clearly does so on a category-basis. Instead of sorting everything as a group, it sorts only within each category (which aren’t visible in this view).
I think that the category view should not ever sort, but should instead display values in the order added. The alphabetical view should sort across all items, since the categories aren’t visible at this point anyway. VS.NET works the same way.
|
|
Technical Support
|
Aug 24, 2005 - 12:35 PM
|
Thank you for your comments and suggestions. To fix the behavior, please do the following three steps: - Initialize
m_bSortedValues to false in the CExtPropertyGridWnd::CExtPropertyGridWnd() constructor; - Initialize
m_bSortedValues to true in the CExtPropertyGridWndSorted::CExtPropertyGridWndSorted() constructor; - Update the source code for the
CExtPropertyGridWndSorted::PropertyStoreSynchronizeOneLevel() method:void CExtPropertyGridWndSorted::PropertyStoreSynchronizeOneLevel(
CExtPropertyItem * pPropertyItem,
CExtPropertyItem * pParentItem // = NULL
)
{
ASSERT_VALID( this );
ASSERT_VALID( pPropertyItem );
pParentItem;
if( pPropertyItem->IsKindOf(RUNTIME_CLASS(CExtPropertyValue)) )
{
HTREEITEM htiParent =
ItemGetRoot();
ASSERT( htiParent != NULL );
HTREEITEM hTreeItem = NULL;
if( ! m_bSortedValues )
{
hTreeItem =
PropertyItemInsert(
pPropertyItem,
-1,
htiParent,
false
);
}
else
{
hTreeItem =
PropertyItemInsertAlphabetic(
pPropertyItem,
htiParent,
false
);
}
// commented is the bug fix by Maurizio Pesce
// properties are enabled to be hidden in grids
// ASSERT( hTreeItem != NULL );
// if( hTreeItem == NULL )
// return;
hTreeItem;
return;
} // if( pPropertyItem->IsKindOf(RUNTIME_CLASS(CExtPropertyValue)) )
INT nIndex, nCount = pPropertyItem->ItemGetCount();
for( nIndex = 0; nIndex < nCount; nIndex ++ )
{
CExtPropertyItem * pChildItem =
pPropertyItem->ItemGetAt( nIndex );
PropertyStoreSynchronizeOneLevel( pChildItem, pPropertyItem );
} // for( nIndex = 0; nIndex < nCount; nIndex ++ )
}
|
|
JAVIER SUAREZ
|
Aug 22, 2005 - 8:45 AM
|
We’ve been trying to add docking functionality to the vertical bar and customdrawn bar in the PageContainer sample but have had no luck in being able to re-dock/move the windows during runtime. Is this possible? Thanks.
|
|
Technical Support
|
Aug 23, 2005 - 12:01 PM
|
To make the horizontal and vertical page containers re-dockable, just add the CBRS_GRIPPER style to the code for creating both m_wndResizableBarH and m_wndResizableBarV bars in the CMainFrame::OnCreate() method of the PageContainer sample application. Please do not forget to clean the control bars’ state in the system registry by deleting the HKEY_CURRENT_USER\Software\Foss\PageContainer registry key. You cannot make the custom drawn page container re-dockable because it is contained by the CDemoMiniFrameWnd floating mini frame window,which is not a redockable control bar. So, you need to create the CCustomDrawnPageContainer window inside CExtControlBar instead of the CDemoMiniFrameWnd window.
|
|
Mel Sampat
|
Aug 18, 2005 - 11:28 AM
|
I have a splitter with 2 rows. At runtime, I want to dynamically show or hide the bottom row. I tried doing SetRowInfo(1, 0, 0) to set the row’s size to 0, but that doesn’t have any effect. Can you suggest a way to do it, or provide some sample code? Ideally, I’d like a function as follows: void CMainFrame::ShowBottomRow(BOOL bShow); Thanks. -Mel
|
|
Technical Support
|
Aug 18, 2005 - 2:24 PM
|
To perform this task, it would be much easier to forget about the splitter control and use resizable control bars (the CExtControlBar class) without caption (i.e. the CBRS_GRIPPER style is not applied) instead. Please take a look at the PageNavigator and PageContainer sample applications. PageNavigator uses the splitter window in which the page navigator control is inserted into the splitter’s left pane and cannot be hidden. The PageContainer application uses the resizable control bar and you can show/hide both horizontal and vertical page containers with the View pop-up menu in the menu bar. There is no visual difference between resizable control bars and splitters.
|
|
Mel Sampat
|
Aug 18, 2005 - 4:35 PM
|
Thanks, that’s a good idea. Is it possible to make the CExtControlBar a child of another existing splitter pane? I have a UI similar to Outlook Express. A Tree View on the left side and a "details" view on the right side, with a vertical splitter in between. I want to add a CExtControlBar where the message body would be dispayed in the Outlook Express UI. So this control bar would be a child of the 2nd column of the vertical splitter, right? How do I create it? I tried this: CExtControlBar m_wndNotesContainer; // declared in MainFrm.h m_wndNotesContainer.Create(NULL, m_wndSplitter.GetPane(0, 1), 0, WS_CHILD|WS_VISIBLE|CBRS_TOP|CBRS_FLYBY|CBRS_SIZE_DYNAMIC); But the above prevents my app from starting (not sure why). Any ideas?
|
|
Technical Support
|
Aug 19, 2005 - 8:42 AM
|
It is not possible to use a control bar inside another control bar directly. The control bars are not splitters, but you can use them to create a GUI absolutely similar to the GUI based on nested splitters. You should dock a control bar with the left side of the frame window. This control bar will be a tree view bar and it will occupy the entire column on the left side: pTreeViewControlBar->DockControlBarInnerOuter(
AFX_IDW_DOCKBAR_LEFT, true ); The table of messages is the main view window in your SDI application. It is not a child of any control bar. If you need a message preview control bar at the bottom of the table of messages (which is, as we said above, a child view window), then this bar can be docked as follows: pMessagePreviewControlBar->DockControlBarInnerOuter(
AFX_IDW_DOCKBAR_BOTTOM, true ); The message preview control bar should be docked after the tree view control bar. Finally, if you need a news tree in the same column with the mail folders tree, then you can create a resizable control bar for this tree and dock it relative to the main folders tree: pTreeViewControlBar->DockControlBarLTRB(
pNewsTreeControlBar, AFX_IDW_DOCKBAR_BOTTOM ); Of course, we assume that all the control bars were created without CBRS_GRIPPER style and have no captions. If so, you will get a splitter-like layout similar to that in Outlook Express. You don’t need to create one control bar inside another. The CExtControlBar::DockControlBarLTRB() methods allow you to dock one bar relative to other already docked control bar and, as result, two control bars will occupy the area previously occupied by one control bar. As we said before, you will be able to hide any of your control bars any time and that is the main advantage which is not provided by splitter windows. If you encounter any difficulties, just send us your project or source code so that we can help you.
|
|
Simon DESEE
|
Aug 13, 2005 - 12:58 PM
|
I use ProfUIS 2.42. I want to add customization functionnality to my application. But an error occurs at this line: VERIFY(CExtCustomizeSite::MenuInfoAdd(this, _T("Default"), IDR_MAINFRAME, true, false));//, RUNTIME_CLASS(CMainFrame))); I can read this on the output window: Warning: Cannot load CExtCustomizeCmdTreeNode from archive. Class not defined. CArchive exception: badClass. I found that there is no CExtCustomizeCmdTreeNode class on the CArchive object use by the extcustomize.cpp file at the line 2033:
CRuntimeClass * pRTC = ar.ReadClass();
Where can the problem come from ? I use a menu bar and many toolbar. The menu bar has a combo box at the right of the menus and one of my toolbars has a combobox. Thanks.
|
|
Technical Support
|
Aug 13, 2005 - 1:17 PM
|
To help you, we need at least the following information:
1) Which version of Prof-UIS are you using (2.40 or 2.42)?
2) Which configuration of Prof-UIS is used in your project (ANSI, MBCS, or UNICODE)?
3) Whether you application SDI or MDI?
4) Whether your application run successfully at least once before the problem appeared?
Additionally we should note: if you can send us your project, please do this. The problem will be quickly pinpointed and fixed in this case. Otherwise,please send us the source of your main frame window, or, at least the main frame class declaration in the .H file and two methods in the .CPP file: OnCreate() and DestroyWindow() .
|
|
Simon DESEE
|
Aug 14, 2005 - 2:40 AM
|
Ok, I send to you a mail with this informations and source code. Thanks.
|
|
Technical Support
|
Aug 14, 2005 - 11:49 AM
|
|
|
Krustys Donuts
|
Aug 12, 2005 - 3:21 PM
|
Hi, I’m trying to get my dialog to do something when the user clicks on an ellipsis button (CExtGridCell with the __EGCS_BUTTON_ELLIPSIS style bit ste). However, when I traced through the source, I saw that the OnButtonPressed handler handles three button types (updown/up, updown/down, and dropdown), but not the ellipsis! Would it be possible to add this functionality soon, and have it call something in CExtTreeGridWnd?
|
|
Technical Support
|
Aug 13, 2005 - 12:56 PM
|
There must be some misunderstanding. The CExtGridCell::OnButtonPressed() virtual method is invoked from the CExtGridWnd::OnGridTrackCellButton() button. Please run the PropertyGridSample application and click the ellipsis button in the Misc/File property value. You can see how the CExtGridCellFile::OnButtonPressed() method shows the standard File Open dialog.
|
|
Krustys Donuts
|
Aug 14, 2005 - 11:46 AM
|
The idea behind my approach is that I don’t want to have to subclass every Prof-UIS class just to implement slightly customized behavior. That’s why I was poking into CExtGridCell to see if would be possible to add some generic behavior. Ideally, it would just call back into the gridwnd, and then I could add my custom code elsewhere... like in my subclass CExtGridCtrl class.
|
|
Technical Support
|
Aug 14, 2005 - 12:22 PM
|
We agree with you. We already added a set of new OnGridCell...() methods to the CExtGridWnd class. It seems we should extend the number of such methods to cover all the possible cell events.
|
|
Krustys Donuts
|
Aug 14, 2005 - 9:05 PM
|
Yes, please, that would be fantastic! We would much prefer this sort of approach vs. having tons of subclasses in our projects.
|
|
JAVIER SUAREZ
|
Aug 11, 2005 - 11:52 AM
|
Hi, I’ve run into an issue on some samples (MDI_DynamicBars, for example) where it tries to link to ProfUIS242md.lib or ProfUIS242m.lib, and yet there is no build configuration for profuislib that makes those libs. Every solution configuration for the profuislib project adds a ’y’ or an ’s’ to the lib name depending if it is static or dymanic, yet some samples try to link to a lib with neither a ’y’ or ’s’. Thanks, JT Cubic Defense
|
|
Technical Support
|
Aug 11, 2005 - 12:46 PM
|
The profuisdll project produces Prof-UIS DLL modules and their LIB stubs. This project includes all the features of the library. The profuislib project produces static libraries which include all the library features which have no dependency from the resources. The toolbar/menu customization, dynamic resizable control bars, icon editor dialog and color editor dialog are components which depend on the resources and they are excluded from the profuislib project. As you can see the MDI_DynamicBars, SDI_DynamicBars, StyleEditor and IconEditor applications are based on the resource dependent library features and can be linked only with the libraries produced by the profuisdll project.
You can see the full list of Prof-UIS configurations in the Prof-UIS Build Configuration article.
|
|
David Baginski
|
Aug 11, 2005 - 7:12 AM
|
I"m using the CExtTabMdiOneNoteWnd class and adding the customary " *" to the document title when it is dirty. I’d like to know how to update the tab bar to accomidate the increased lenght of the document title. I tried calling Invalidate() which did update the MDI tab with a "..." since it could not accomidate the new length, but I can I get the MDI tab to recalculate its layout as well.
|
|
Technical Support
|
Aug 11, 2005 - 11:52 AM
|
Please invoke the UpdateTabWnd( true ) method of the CExtTabMdiOneNoteWnd class instance. This method synchronizes all the tab items and remeasures them.
|
|
Niksa Orlic
|
Aug 9, 2005 - 12:57 PM
|
I want to change the CExtPropertyCategory title when user clicks a button. I construct the category item using this code: m_pConfigurationCategory =
new CExtPropertyCategory(configurationCategoryName);
m_catBuildConfigurations->ItemInsert(m_pConfigurationCategory); Where m_pConfigurationCategory is CExtPropertyCategory* - everything works fine here. When a button is pressed, the following code is executed: m_pConfigurationCategory->NameSet(someText);
m_propertyCtrl.PropertyStoreSynchronize(); m_propertyCtrl is CExtPropertyGridCtrl. The program crashes inside the call to PropertySyncronize(), with the following error: The value of ESP was not properly saved across a function call. This is
usually a result of calling a function declared with one calling convention
with a function pointer declared with a different calling convention. If I don’t call PropertySyncronize(), the visible name on the screen is not changed. What am I doing wrong? Best regards, Niksa
|
|
Technical Support
|
Aug 10, 2005 - 12:49 PM
|
We updated the source code both for the CExtPropertyGridCtrl class and the classes implementing its parts. Now the property grid control is much more safer for rebuilding tree grid’s content when finalizing the input in the grid cell. Drop us e-mail so that we can provide you with the latest source code. Additionally we should note that synchronization of the property store resets the collapsed/expanded state for all the rows in the tree grids into their initial state. So, it is also possible to update text in the grid cell describing the renamed property category instead of invoking the property store synchronization control. First of all, your code should rename the property category as you did before: CExtPropertyCategory * m_pConfigurationCategory = . . .
LPCTSTR strNewNameOfTheCategory = . . .
m_pConfigurationCategory->NameSet(
strNewNameOfTheCategory
); Then your code should access all the grid cells instantiated for this property category in all the tree grid windows created in the property grid control: CExtPropertyGridCtrl * pPGC = . . .
CTypedPtrArray
< CPtrArray, CExtPropertyGridWnd * >
arrGrids;
pPGC->OnPgcQueryGrids( arrGrids );
INT nGridIdx = 0;
for( ; nGridIdx < arrGrids.GetSize(); nGridIdx ++ )
{
CExtPropertyGridWnd * pGrid =
arrGrids[ nGridIdx ];
ASSERT_VALID( pGrid );
HTREEITEM hTreeItem =
pGrid->PropertyItemToTreeItem(
m_pConfigurationCategory
);
if( hTreeItem == NULL )
continue;
CExtGridCell * pCellCategory =
pGrid->ItemGetCell( hTreeItem, 0 );
ASSERT_VALID( pCellCategory );
pCellCategory->TextSet(
strNewNameOfTheCategory
);
if( ! pGrid->IsWindowVisible() )
continue;
int nPlainRowIndex =
pGrid->ItemGetVisibleIndexOf(
hTreeItem
);
if( nPlainRowIndex < 0 )
continue;
CRect rcCellExtra;
pGrid->GridCellRectsGet(
0,
nPlainRowIndex,
0,
0,
NULL,
&rcCellExtra
);
pGrid->InvalidateRect(
&rcCellExtra
);
pGrid->UpdateWindow();
}
|
|
Niksa Orlic
|
Aug 10, 2005 - 1:38 PM
|
My email is niksa.orlic AT fer.hr. Another question: I want resizable control bar to look just like fixed size panel (with toolbar-like gripper instead of titlebar). Is there any ’easy’ way to do this, or I have to mess with paint manager? Thanks, Niksa
|
|
Technical Support
|
Aug 11, 2005 - 11:50 AM
|
We have sent you instructions on how to download the latest source code.
Please let us know details on the custom panel bar. Would you like to see the dot-based gripper like in toolbars when the style 2003 is applied or you want to see the toolbar used in the caption of the panel bar as it is done in the task area in MS Word 2003? Could you tell us whether you have seen the bar you need and send us a screen shot? We will help you get exactly what you need.
|
|
Niksa Orlic
|
Aug 12, 2005 - 3:42 AM
|
|
|
Technical Support
|
Aug 14, 2005 - 12:26 PM
|
Thank you for sharing your ideas and requirements with us. We are working on a new sample application which will demonstrate the customizable behavior of resizable control bars and we will implement the control bars like on your screen shot in it. Could you wait a few days until this application is ready?
|
|
Niksa Orlic
|
Aug 16, 2005 - 12:29 AM
|
No problem and thanks again.
Niksa
|
|
Wilhelm Falkner
|
Aug 9, 2005 - 12:00 PM
|
Hi, it seems to me, that OnPaint is not called when inherited from CExtResizableDialog. If I use CDialog instead, all works fine. What I have done wrong??
TIA Willi
|
|
Dusan Gibarac
|
Apr 14, 2007 - 6:32 PM
|
I have to ’paint’ on CExtResizablePropertyPage. Implementing the same WM_PAINT technique there does not work. WM_PAINT did not happened. We have in the code:
IMPLEMENT_DYNCREATE(CKWP_Computer, CExtResizablePropertyPage)
CKWP_Computer::CKWP_Computer() : CExtResizablePropertyPage(CKWP_Computer::IDD) { }
and
class CKWP_Computer : public CExtResizablePropertyPage { DECLARE_DYNCREATE(CKWP_Computer) protected: virtual LRESULT WindowProc( UINT message, WPARAM wParam, LPARAM lParam ) { if( message == WM_PAINT ) { AfxMessageBox("painting"); CPaintDC dc( this );
...
|
|
Technical Support
|
Apr 15, 2007 - 11:16 AM
|
We guess the page window contains some control(s) which cover the client area of the page completely.
|
|
Technical Support
|
Aug 10, 2005 - 12:16 PM
|
If you take a look at the declaration of CExtResizableDialog , you will see that its parent classes are wrapped in templates. The template classes cannot have message handlers like OnPaint() for implementing window behavior and appearance. So we had to implement the WindowProc() virtual method in them. The CExtWS template class adds a theme-based background to the resizable dialog window and eats up the WM_PAINT standard windows message in its WindowProc() method. That is why the OnPaint() method is not invoked in dialog classes derived from the CExtResizableDialog class. You can also override the WindowProc() method and handle the WM_PAINT standard windows message there: class C_Your_Dialog : public CExtResizableDialog
{
protected:
virtual LRESULT WindowProc( UINT message, WPARAM wParam, LPARAM lParam )
{
if( message == WM_PAINT )
{
CPaintDC dc( this );
//
// YOUR CUSTOM PAINTING CODE GOES HERE
//
return 0;
}
return CExtResizableDialog::WindowProc( message, wParam, lParam );
}
};
|
|
Wilhelm Falkner
|
Aug 11, 2005 - 1:22 AM
|
Thanks for your help, works fine!! Willi
|
|
Oliver Rogall
|
Aug 9, 2005 - 3:02 AM
|
With version 2.33 and 2.42 of Prof-UIS I get no menus in Windows NT (for test I use your sample sdi-m.exe). I build the libraries both with Visual Studio .NET 2003 and Visual Studio 6.0 but the problem is always the same. When I install an older version like 2.27 of Prof-UIS the applications runs fine in Windows NT?
I read the post "Menubar itens don’t appear in Windows NT" but this does’nt solve my problem.
Best regards Oliver Rogall
|
|
Oliver Rogall
|
Aug 9, 2005 - 8:49 AM
|
Thanks, now it works fine.
Best regards Olvier Rogall
|
|
Technical Support
|
Aug 9, 2005 - 5:49 AM
|
Thank you for the bug report. It is not difficult to fix it. Please find the below line in the .../Prof-UIS/Src/ExtPopupMenuWnd.cpp file (there are two entries of it): WS_EX_NOINHERITLAYOUT and replace each line with: ( g_PaintManager.m_bIsWin2000orLater ? (WS_EX_NOINHERITLAYOUT) : 0 )
|
|
claude laflamme
|
Aug 8, 2005 - 9:30 AM
|
Hi, I have a slider created into a toolbar. I need my toolbar to use maximun space available when it is docked. So, I’ve make it single on row and stretch it. But, if I try to resize the slider, it always try to resize the toolbar causing to resize the slider again and again and again. So, how can I implemet it? Thanks
|
|
Technical Support
|
Aug 9, 2005 - 4:28 AM
|
The CExtMenuControlBar class implements a menu bar and it is a kind of the CExtToolControlBar class that implements a toolbar. It is possible to make toolbar occupy a full row/column automatically by overriding the CExtToolControlBar::_GetFullRowMode() internal virtual method like as follows: bool C_YOUR_ToolControlBar::_GetFullRowMode() const
{
ASSERT_VALID( this );
return true;
} It is also possible to stretch some toolbar button to fit all the space. By default, the toolbar button with the attached window measures its size by simply returning width/height of the attached window. So, you will need to implement custom measure technique. This task should be solved by overriding the CExtToolControlBar::_RecalcPositionsImpl() internal virtual method. Your implementation of this method should invoke parent’s method, analyze space between the last toolbar button and the end of the toolbar’s client area. This can be done via comparison of two rectangles: one is the client rectangle of the toolbar window and another is that returned by the CExtBarButton::Rect() method of the last button object in the toolbar. If your code detects some free space or collision between the last button’s area and the end of the client rectangle, then the window size of the combo box should be adjusted according to the detected size difference. In this case, you should invoke the parent CExtToolControlBar::_RecalcPositionsImpl() method second time to apply new positions of toolbar buttons according to the changes of the combo box’s size. If it’s difficult for you, we can help you by coding a ready-to-use solution.
|