Subject |
Author |
Date |
|
tera tera
|
Oct 19, 2008 - 8:28 PM
|
Hello. I want to change a status message displayed in this point.
In that case, should I use the following commands? LRESULT CMainFrame::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
{
LRESULT lResultX;
LRESULT lResult;
bool blRet; switch( message )
{
case WM_SETMESSAGESTRING:
Status Message....
return 0;
default:
break;
} lResult = CMuMdiFrame::WindowProc( message , wParam, lParam);
|
|
Technical Support
|
Oct 21, 2008 - 12:56 PM
|
By default Prof-UIS classes do not send a WM_SETMESSAGESTRING message. Instead, they use the CExtControlBar::stat_SetMessageString() method for accessing the default message pane in the status bar. You can turn on sending a WM_SETMESSAGESTRING message by CExtControlBar::stat_SetMessageString() by invoking: CExtControlBar::g_bUseCmdManagerForSetMessageString = false;
|
|
Anil Siddhpura
|
Oct 19, 2008 - 1:02 AM
|
1. I want to enlarge the size of print preview toolbar. 2. How can I get the current theme color ? 3. How can I set the text color of PageContainer control ? 4 .How can I set the text color of each control exist in my project ?
|
|
Technical Support
|
Oct 25, 2008 - 8:47 AM
|
1. What exactly you want to change? The height of a toolbar or the height of each button so their icons look bigger?
2. There are many theme colors. What the color exactly you wants to retrieve?
3. We guess you mean the text color of the captions in the CExtPageContainerWnd control. This page caption is measured in the CExtPageContainerWnd::OnPageContainerMeasureCaptionSize() virtual method and painted in the CExtPageContainerWnd::OnPageContainerDrawCaption() virtual method. You should override this method to paint text with a custom color.
4. Many controls in Prof-UIS have the SetBkColor() /GetBkColor() and SetTextColor() /GetTextColor() methods which are used for changing their text and background colors. If you need to change some color in some control, first take a look at these methods in the corresponding classes.
|
|
Neville Franks
|
Oct 17, 2008 - 11:24 PM
|
I want to prevent the user collapsing a Pane in a CSGExtPageNavigatorWnd Page. I’ve looked through all the CExtPageNavigatorWnd::ITEM_PANE_INFO and CExtPageNavigatorWnd::PAGE_ITEM_INFO etc. functions and can’t find a way to do this. How can I accomplish this? Thanks,
Neville, http://www.surfulater.com
|
|
Neville Franks
|
Oct 19, 2008 - 5:21 PM
|
Further to my last request I want to start with certain Panes Expanded and others Collapsed. How can I do that? Thanks,
Neville, http://www.surfulater.com
|
|
Technical Support
|
Oct 25, 2008 - 8:39 AM
|
You can do this either with CExtPageNavigatorWnd::ItemPaneExpand() or with CExtPageNavigatorWnd::ITEM_PANE_INFO::Expand() .
|
|
Technical Support
|
Oct 25, 2008 - 8:38 AM
|
Since v.2.61 the Page Navigator has supported collapsed/expanded state for each pane like in the Outlook 2007 Navigation Pane. Together with the new functionality we added new methods:
ItemPaneExpand() , ItemPaneIsExpanded() , ItemPaneExpandableGet() , and ItemPaneExpandableSet() methods to the CExtPageNavigatorWnd class and Expand() , IsExpanded() , ExpandableGet() , and ExpandableSet() methods to the CExtPageNavigatorWnd::ITEM_PANE_INFO class.
You can disable page collapsing/expanding with the ItemPaneExpandableSet method.
|
|
Robert Webb
|
Oct 16, 2008 - 1:47 AM
|
The file menu in a ribbon bar is kind of ugly and inconvenient (not your fault if just copied from MS). For example, submenus have their entries starting at the top rather than starting at the level of the submenu selected. Consider the Unlock menu below. The user must move the mouse down to the item, then back up to the top to select one of its sub-items. It’s kind of cumbersome compared with a traditional menu. Is there an alternative you can suggest? Also, the right part of the menu is usually just a large mostly empty space. I’m not sure why it’s so big. Can it be adjusted? And finally, we handle our MRU list (most-recently used) differet from the standard way, and display something more than just the file name. Is there a way I can change the MRU list shown on the right to contain my own items? Thanks,
Rob.
|
|
Antonio Pelli Neto
|
Aug 7, 2009 - 3:04 PM
|
I’m facing a big problem trying to include the RibbonNodeFile in the Formula Grid Sample. I tried everything including copying the example from RibbonBars, but it didn’t work. I’m moving from CodeJock to Prof-UIS, but the help really didn’t help me. Pelli
|
|
Technical Support
|
Aug 10, 2009 - 6:20 AM
|
The FormulaGrid sample application demonstrates a simplified ribbon bar layout without the ribbon file button (a.k.a. application button). Some applications do not require rich and big ribbon file menu and we just used the FormulaGrid sample application to demonstrate such ribbon bar layout. The CMyRibbonBar class in this sample application have the following implementations of the ribbon bar’s virtual methods:
virtual bool Ribbon_FileButtonInit() { return false; }
bool RibbonLayout_IsFrameIntegrationEnabled() const { return false; }
If you want to initialize the ribbon file menu, then you should remove these virtual methods from the CMyRibbonBar class. Then you should initialize the ribbon file button like the RibbonBar sample application does.
|
|
Antonio Pelli Neto
|
Aug 7, 2009 - 3:03 PM
|
|
|
Antonio Pelli Neto
|
Aug 7, 2009 - 3:03 PM
|
|
|
Technical Support
|
Oct 21, 2008 - 1:08 PM
|
Please compile and run the following modified version of the RibbonBar sample we have just created for you and take a look at the usage of the stat_MyCreateRibbonGalleryItem() function in it:
http://www.prof-uis.com/download/forums/RibbonBar-Custom-Draw-File-Button-Gallery.zip
In most cases ribbon galleries contain only big icons. The stat_MyCreateRibbonGalleryItem() function creates big icons displaying text like you need.
|
|
Robert Webb
|
Oct 23, 2008 - 1:47 AM
|
Is there a way to change the height of that gallery? It seems to be a fixed height that isn’t set anywhere in the sample. But as you can see in my original screenshot, the menu is taller than the gallery, and when there’s enough stuff in the gallery to need a scroll bar it seems a shame not to make the most of the full menu height. Ideally I’d just want to make it the same height as the menu. Thanks,
Rob.
|
|
Technical Support
|
Oct 23, 2008 - 2:01 PM
|
Here is how the size of a gallery control of the ribbon file menu is initialized in the constructor of the CExtRibbonNodeFile class: m_sizePopupGalleryControl = m_sizePopupGalleryControlMin =
m_sizePopupGalleryControlMax = CSize( 350, 330 ); We have modified the source code of the CMainFrame::_InitRibbon_FileMenu() method in the RibbonBar sample application for increasing height of this gallery from 330 to 500 pixels: CExtRibbonNodeFile * CMainFrame::_InitRibbon_FileMenu()
{
CExtRibbonNodeFile * pRibbonNodeFile = new CExtRibbonNodeFile;
pRibbonNodeFile->m_sizePopupGalleryControl
= pRibbonNodeFile->m_sizePopupGalleryControlMin
= pRibbonNodeFile->m_sizePopupGalleryControlMax
= CSize( 350, 500 );
pRibbonNodeFile->CmdKeyTipSet( new CExtCustomizeCmdKeyTip( __EXT_MFC_SAFE_TCHAR( _T(’F’) ) ), false );
pRibbonNodeFile->m_keyTipOptionsButton.KeyCodeAdd( DWORD(’T’) );
pRibbonNodeFile->m_keyTipExitButton.KeyCodeAdd( DWORD(’X’) );
. . . You can increase/decrease the width and/or height of this gallery. The size of the second level popup sub-menus will be adjusted automatically. I.e. the second level popup sub menus will cover the gallery inside the ribbon file menu.
|
|
Robert Webb
|
Oct 21, 2008 - 9:35 PM
|
Hey, this looks great, just what I needed. Thanks, Rob.
|
|
Technical Support
|
Oct 18, 2008 - 10:15 AM
|
We assume the ribbon’s file menu is a very specific UI part. It has approximately the same size in all the applications of Office 2007 and contains approximately the same set of items. We hope it’s not our fault because the ribbon UI have not been invented by us.
First of all, the ribbon file button is a ribbon gallery. All ribbon gallery buttons display a popup menu with gallery control at top and, optionally, a set of menu items at bottom. All ribbon galleries are resizable in both directions or in vertical direction only. But the ribbon file button is an exception. Unlike other galleries, it has a specific skinned look, menu items on the left side, a gallery control on the right side, optional two buttons at bottom or one of these buttons (Options and/or Exit), popup sub menus of the menu level next to the top ribbon file gallery level also have a specific look and position, which is designed to cover gallery control. But the ribbon file gallery and other galleries use the same APIs and virtual methods. The gallery control inside ribbon file button does not contain MRU entries. It does contain what you have inserted. The CMyRibbonBar::OnRibbonGalleryInitContent() virtual method in the RibbonBar sample application initializes all the gallery controls you can come across within the ribbon bar including gallery control inside ribbon file menu. The ribbon file button is initialized at the end of this method. The ribbon gallery control (the CExtRibbonGalleryWnd class) is advanced version of Prof-UIS toolbox control (the CExtToolBoxWnd class). So, gallery items are toolbox items. You should simply initialize your MRU items as toolbox items. You should implement the CExtRibbonPage::OnRibbonGalleryItemSelEndOK() virtual method in your CExtRibbonBar -derived class to handle selection of the ribbon gallery items.
|
|
Robert Webb
|
Oct 20, 2008 - 7:22 PM
|
Ah thanks, I hadn’t realised the MRU list was filled in elsewhere. I have my MRU list working the way I want now. Weird that the MRU menu is handled differently from other submenus though, which otherwise look similar and appear in the same place. I’d like to show items in the MRU list similar in style to those in the SaveAs list of the ribbon sample, that is, with a bold headline and non-bold text underneath. For menus this is done using __ECTN_BOLD_IN_MENU and SetTextMenuExtended(). Since the MRU list is done as a gallery, how would I achieve the same effect? Thanks, Rob.
|
|
Robert Webb
|
Oct 16, 2008 - 1:48 AM
|
(Sorry, don’t know how the subject came out as just "F"!)
|
|
Robert Webb
|
Oct 16, 2008 - 1:35 AM
|
(1) Is it possible to have tool tips for ribbon bar tabs? How would I do that? (2) Is it possible to display an icon to the left of the text in ribbon bar tabs? That is, an icon for each tab. Thanks,
Rob.
|
|
Technical Support
|
Oct 17, 2008 - 1:08 PM
|
Here is the modified version of the CMainFrame::_InitRibbonPage_Home() method from the RibbonBar sample which makes the Home tab item in the ribbon bar display a big screen tip (we have initialized it with the same text and image as the ribbon file menu): CExtRibbonNode * CMainFrame::_InitRibbonPage_Home()
{
CExtRibbonNodeTabPage * pRibbonNodeTabPage = new CExtRibbonNodeTabPage( 0L, NULL, _T("Home") );
CExtCustomizeCmdScreenTip * pCmdScreenTip = new CExtCustomizeCmdScreenTip;
pCmdScreenTip->CaptionMainSet( _T("Application Button") );
pCmdScreenTip->TextMainSet( _T("Click here to open, save or print,\nand to see everything else you can\ndo with the document.") );
pCmdScreenTip->BmpMainGet().LoadBMP_Resource( MAKEINTRESOURCE(ID_FILE_DLB_TIP_IMAGE) );
pCmdScreenTip->BmpMainGet().Make32();
pCmdScreenTip->BmpMainGet().AlphaColor( RGB(255,0,255), RGB(0,0,0), 0 );
pRibbonNodeTabPage->CmdScreenTipAttach( pCmdScreenTip );
pRibbonNodeTabPage->CmdKeyTipSet( new CExtCustomizeCmdKeyTip( __EXT_MFC_SAFE_TCHAR( _T(’H’) ) ), false );
pRibbonNodeTabPage->InsertNode( NULL, _InitRibbonNode_Home_Clipboard() );
pRibbonNodeTabPage->InsertNode( NULL, _InitRibbonNode_Home_Font() );
pRibbonNodeTabPage->InsertNode( NULL, _InitRibbonNode_Home_Paragraph() );
pRibbonNodeTabPage->InsertNode( NULL, _InitRibbonNode_Home_Style() );
pRibbonNodeTabPage->InsertNode( NULL, _InitRibbonNode_Home_Find() );
return pRibbonNodeTabPage;
} The icons on ribbon tabs are not supported at this moment. Besides, the Windows Vista UI Guidelines strongly recommend not to use icons on tabs: http://msdn.microsoft.com/en-us/library/aa511493.aspxHere is the text from the document referred above: Don’t put icons on tabs. Icons usually add unnecessary visual clutter, consume screen space, and often don’t improve user comprehension.
|
|
Robert Webb
|
Oct 16, 2008 - 1:30 AM
|
I presume it’s not possible to put the ribbon bar vertically down the left or right side? Any plans to allow something like that? With most monitors being wide-screen these days, vertical real estate is a premium, so it’s a better use of space to have all controls down the sides. Thanks, Rob.
|
|
Technical Support
|
Oct 17, 2008 - 9:04 AM
|
The ribbon controls are not very friendly to wide screen monitors because the ribbon can be horizontal oriented only. The ribbon button layout is designed for adaptive horizontal compressing. That is why the ribbon is not a vertical control. Of course, it’s potentially possible to improve the ribbon bar control and rotate it. But we think it will contain too much buttons with vertically oriented text so it will not be convenient.
|
|
Robert Webb
|
Oct 16, 2008 - 1:26 AM
|
Hi,
When using the Office 2007 Obsidian theme, which is our prefered one, the area behind the quick access bar is almost black. But our icons are designed for use on a light background and are really hard to make out. The ribbon itself still has a light background, so designing icons that show up well on both is somewhat difficult.
I notice that when the window loses focus, it sometimes goes grey, and then the icons are clearly visible. I would suggest that just for the QA area this lighter grey is always used (keeping dark grey for the rest of the title bar). Is there a straight forward way for us to make this happen?
I say "sometimes goes grey" above because I’m noticing right now that the window title and QA stay very dark when the window loses focus, until another window is dragged over it and dragged off again, causing a redraw which draws in the lighter grey. So it’s not redrawing properly when the window loses focus. This is using your Office demo by the way, not my own code. I’ve seen a lot of redraw issues using Prof-UIS, which worries me. Dark background when window has focus, icons are hard to see:
Light background when window loses focus (if it redraws correctly), icons are easier to make out:
Rob.
|
|
Technical Support
|
Oct 17, 2008 - 9:03 AM
|
You should create and use your own CExtPaintManagerOffice2007_R2_Obsidian -derived class: class CYourPaintManger : public CExtPaintManagerOffice2007_R2_Obsidian
{
public:
CYourPaintManger()
{
. . .
}
};
. . .
VERIFY( g_PaintManager.InstallPaintManager( new CYourPaintManger ) );
The constructor of your paint manager class should load skinned bitmap parts for loading lighter version of the quick access toolbar background. The parent class constructor will load all the default bitmaps. The constructor of your class will re-load your custom bitmaps. Please take a look at the content of the .../Prof-UIS/Include/Resources/Res2007/ folder. It contains collection of bitmaps for Office 2007 themes. All the bitmaps have names similar to their identifiers. The IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_LEFT_R3_OBSIDIAN.bmp and IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_RIGHT_R3_OBSIDIAN.bmp files are defining dark quick access toolbar background which you would like to make lighter. Please find where the IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_LEFT_R3_OBSIDIAN and IDB_EXT_2007_RIBBON_NC_CORNER_ACTIVE_RIGHT_R3_OBSIDIAN bitmaps are loaded in the constructor of the CExtPaintManagerOffice2007_R2_Obsidian class. Copy loading code into the constructor of your paint manager class and load these bitmaps from your lighter bitmap resources. Please note, the CExtPaintManagerOffice2007_R2_Obsidian class uses different bitmaps and painting code for quick access toolbar background in the skinned caption area and in the DWM based glass area of Windows Vista. But in case of Vista the background is enough light and you probably will not need to change it.
|
|
Krustys Donuts
|
Oct 16, 2008 - 1:20 AM
|
Dear Support, My CExtPopupMenuWnd code is below:
HMENU oMenu; { if((oMenu = LoadMenu(GlobalInstance,MAKEINTRESOURCE(IDR_menuTpContextMenu)))!=NULL) //!Get the sub-menu.CMenu menu; menu.Attach(oMenu); //!Use the Prof-uis menu class.CExtPopupMenuWnd* pPopup = pPopup->UpdateFromMenu(GetParent()->m_hWnd, &menu, new CExtPopupMenuWnd;true, true, true); //!Use the name of TP A for the header of this context menu.pPopup->MenuCaptionTextSet(strTpA.c_str()); //!Put the name of TP B into the ’Transfer from’ and ’Transfer to’ commands.string str = (boost::format(m_st.GetString( IDS_strTransferTo)) % strTpB).str(); pPopup->ItemSetPopupText(pPopup->ItemFindPosForCmdID(ID_TransferAtoB), str.c_str()); str = (boost::format(m_st.GetString( IDS_strTransferFrom)) % strTpB).str(); pPopup->ItemSetPopupText(pPopup->ItemFindPosForCmdID(ID_TransferBtoA), str.c_str());//!Show the menupPopup->TrackPopupMenu( TPM_CENTERALIGN | TPMX_NO_CMD_UI | TPMX_HIDE_KEYBOARD_ACCELERATORS, point.x, point.y);
This code gets me what I want except there is an empty column on the left side of the menu. How can I eliminate this feature. I tried SetLeftColumnWidth(0) and SetLeftColumnWidth(1) withoout luck.
Thanks, Gil
|
|
Technical Support
|
Oct 17, 2008 - 8:50 AM
|
The icon area on the left of a popup menu is a built-in menu part. You can re-paint it without painting anything on it. You should handle a CExtPopupMenuWnd::g_nMsgPopupDrawLeftArea registered message as it is demonstrated in the ProfUIS_Controls sample.
|
|
Neville Franks
|
Oct 15, 2008 - 9:28 PM
|
Q1) I have a class derived from CExtResizableDialog which includes a Toolbar and Tree control. I want to change this to use CExtPageNavigatorWnd inside the CExtResizableDialog and have my Tree control as a Pane inside the CExtPageNavigatorWnd. I have this working but need to get the CExtPageNavigatorWnd to be the same size as as its parent CExtResizableDialog and to resize when it resizes. How do I do this? Q2) Can I use a Toolbar CSGExtToolControlBar as a CExtPageNavigatorWnd Pane? Thanks, Neville
|
|
Technical Support
|
Oct 17, 2008 - 8:47 AM
|
You should create a CExtPageNavigatorWnd window as a child of the dialog window in the dialog’s OnInitDialog() method. Please invoke the dialog’s GetClientRect() and use the obtained rectangle when creating the page navigator control. Then add anchors to the just created page navigator control using the pYourDialog->AddAnchor( pWndPageNavigator->m_hWnd, __RDA_LT, __DRA_RB ); code. This code should be invoked immediately after the page navigator has been created and it will make the page navigator control automatically covering the entire dialog’s surface.
Yes, you can use a Prof-UIS toolbar as a child of any kind of window. It’s possible to make a toolbar having a multi row layout of buttons (so it looks like a palette window with a set of tools). But the CExtToolBoxWnd control demonstrated in the FormEditor sample is a better implementation of the palette control and it supports categories. The most often case of non-redockable toolbar usage is demonstrated in many resizable bars of the ProfStudio sample where a static toolbar is present at top of a dialog window created as a child of a resizable bar. The Solution Explorer and Class View bars contain such toolbars.
|
|
Neville Franks
|
Oct 17, 2008 - 2:20 AM
|
To place the Toolbar inside a CExtPageNavigatorWnd Pane I have created a CExtResizableDialog derived class and insert this in the pane. The RC entry is: IDD_KnowledgeTreePageDLG DIALOG DISCARDABLE 0, 0, 101, 82
STYLE WS_CHILD | WS_VISIBLE
FONT 8, "MS Sans Serif"
BEGIN
CONTROL "",IDR_KnowledgeTreeToolbar,"ProfUIS-ControlBar",0x2034,8,4,57,14
END The Toolbar is displayed but the buttons are bank. If I hover over them the Status Bar displays the correct Tooltips. Clicking on a button does nothing. Looking at CExtBarButton::OnDeliverCmd(), g_CmdManager->CmdGetPtr() returns NULL. The name returned from g_CmdManager->ProfileNameFromWnd() is " PageNavigator-132513112-2708-6032". The ON_UPDATE_COMMAND_UI( ) functions are called for each Toolbar button. The ON_COMMAND_EX() functions are not called. The same Toolbar worked perfectly inside the original CExtResizableDialog I used before embedding a CExtPageNavigatorWnd inside it.
|
|
Technical Support
|
Oct 17, 2008 - 8:39 AM
|
Please make your child dialog, which is inside a page navigator, is using its own command manager’s profile. You should invoke the following code in the dialog’s OnInitDialog() virtual method: static TCHAR g_strCommandProfileNameOfYourDialog[] = _T("MyDialogInisdePageNavigator");
if( ! g_CmdManager->ProfileSetup( g_strCommandProfileNameOfYourDialog, m_hWnd ) )
{
VERIFY( g_CmdManager->ProfileWndAdd( g_strCommandProfileNameOfYourDialog, m_hWnd ) );
} Then invoke the below code before creating your toolbars in the dialog’s OnInitDialog() virtual method so that you can register all the toolbar icons in the appropriate command manager profile. g_CmdManager->UpdateFromToolBar( g_strCommandProfileNameOfYourDialog, ID_YOUR_TOOLBAR_RESOURCE );
|
|
Neville Franks
|
Oct 17, 2008 - 6:15 PM
|
|
|
Neville Franks
|
Oct 16, 2008 - 9:17 PM
|
I have resolved issue 1 with resizing, but would still like help with using a Toolbar as a CExtPageNavigatorWnd Pane. Thanks,
Neville http://www.surfulater.com
|
|
Offer Har
|
Oct 15, 2008 - 8:37 PM
|
Something like ItemSetParent ? Thanks, Ron.
|
|
Technical Support
|
Oct 17, 2008 - 8:44 AM
|
This is provided by the CExtTreeGridWnd::ItemCopyMove() method. It can either move tree brunches or clone them. There is also another CExtTreeGridWnd::ItemCopyMoveTest() method, which allows you to determine whether you can move a tree item or not. It’s not possible to change the parent item of a tree item to its child item.
|
|
Offer Har
|
Oct 16, 2008 - 4:45 AM
|
I would like to add that I need this for moving a sub-tree, that is, if the node I change the parent to has children, they will move as well...
|
|
Offer Har
|
Oct 15, 2008 - 8:32 PM
|
|
|
Offer Har
|
Oct 15, 2008 - 8:22 PM
|
In the past you said it’s in development - what is the status of this feature? Thanks, Ron.
|
|
Technical Support
|
Oct 27, 2008 - 2:15 PM
|
We mean you can drop us an e-mail so we can provide you with the source code update.
|
|
Offer Har
|
Oct 27, 2008 - 2:49 PM
|
I will e-mail... Just to clarify - is this a new feature in 2.84?
|
|
Technical Support
|
Oct 27, 2008 - 4:14 AM
|
You need the source code update before tree grid becomes sort-able in your projects.
|
|
Offer Har
|
Oct 27, 2008 - 5:02 AM
|
What do you mean? does this work only in 2.84? When is 2.84 going to be releases?
|
|
Technical Support
|
Oct 23, 2008 - 2:12 PM
|
|
|
Offer Har
|
Oct 26, 2008 - 6:47 PM
|
When I enable sorting I get to an assertion here:
bool CExtTreeGridDataProvider::SortOrderGet(
CExtGridDataSortOrder & _gdso,
bool bColumns // true = sort order for columns, false - for rows
) const
{
ASSERT_VALID( this );
_gdso;
bColumns;
// this method must never be invoked
ASSERT( FALSE );
return true;
} Please explain how to implement this sorting.
|
|
Offer Har
|
Oct 15, 2008 - 7:01 PM
|
Dear Support, I need to know if an item in a tree (a row) is visible or not. I see that the function ItemGetVisibleIndexOf can tell me if an item is collapsed or not, but I also need to know if it is within the visible part of the grid - if I have 200 rows, and only 20 are visible, I would to do some periodic checks vs the database only on these 20 items, and leave the other 180 rows to time when they are visible. Thanks, Ron.
|
|
Technical Support
|
Oct 17, 2008 - 8:51 AM
|
This is provided by the CExtTreeGridWnd::ItemCopyMove() method. It can either move tree brunches or clone them. There is also another CExtTreeGridWnd::ItemCopyMoveTest() method, which allows you to determine whether you can move a tree item or not. It’s not possible to change the parent item of a tree item to its child item.
|
|
Technical Support
|
Oct 16, 2008 - 2:15 PM
|
The CExtTreeGridWnd::ItemGetVisibleIndexOf() method returns a zero-based index of tree item in the entire available scrollable range of grid rows. The CExtScrollItemWnd::OnSiwGetVisibleRange() method returns ranges of visible columns and rows. The returned CRect::top and CRect::bottom values specify zero-based row indices of the first and last visible grid rows.
|
|
Offer Har
|
Oct 16, 2008 - 4:22 PM
|
Great - thanks... Any way of moving a sub-tree....? my other question of that day?
|
|
Krustys Donuts
|
Oct 15, 2008 - 3:18 PM
|
I have a CExtTreeGridWnd-derived class that is horizontally scrollable. I would like to fix the position of the first 3 columns such that they do not scroll when the horizontally scrollbar slider is changed. Is this possible? How is it accomplished? Thanks, Gil
|
|
Technical Support
|
Oct 17, 2008 - 9:03 AM
|
|
|
Rubet Louis
|
Oct 15, 2008 - 4:00 AM
|
hi How can I programmatically resize a CExtRibbonNode object, which style is __ECTN_TBB_TEXT_FIELD ? ( I use it in a tool group for which normal and large ILV are removed) How can I programmatically change its font ?
|
|
Technical Support
|
Oct 15, 2008 - 12:33 PM
|
You should invoke the CExtCustomizeCmdTreeNode::TextFieldWidthSet() method of a command tree node which is instantiated with the __ECTN_TBB_TEXT_FIELD style. Finally, after changing the widths of one or more text fields, you should invoke the ribbon bar’s CExtRibbonPage::Ribbon_UpdateLayout() method.
|
|
tera tera
|
Oct 15, 2008 - 1:18 AM
|
Hello. The environment is 6.0 vc++.
When one DLL has 1700 source codes. Build is slow. ( The compiler uses pch. ) debug start takes time.
Please teach a good solution.
|
|
Technical Support
|
Oct 15, 2008 - 12:46 PM
|
We have some small set of sample projects provided with Prof-UIS. Some of them are very simple and some of them are a bit more complex. The compilation very depends on the template class usage. You can make your project compiling faster than the speed of light if you make all the *.H header files containing only class declarations and not including any other *.H header files if possible. This means the following: if you have some CMyClass1 class and it has the CMyClass2 m_someObj; property, then you should change it to CMyClass2 * m_ptrSomeObj; property, remove the #include "MyClass.h" line from the header file, add the class CMyClass2; line and add the #include "MyClass.h" line to the beginning of the .CPP file which contains implementation of the CMyClass2 class. As result, all the header files will include only those header files which are defining base classes. This is very complex work. It’s more complex than it sounds. If you will replace the CMyClass2 m_someObj; class property with the CMyClass2 * m_ptrSomeObj; property, then you will also need to add instantiation code which uses the new C++ operator and deletion code which uses the delete C++ operator and NULL pointer analysis. If you will convert your project according the rules described above, then it will compile as fast as just generated Win32 application even without MFC usage using standard Visual Studio wizard. The debug session startup time is also very linked to template class usage because template based class types are making debug information huge due to long class name strings. So, fastest compilation also needs all the parameters of any methods and functions to be simple class or built-in types. But the class types can have complex template based parent class types. The important thing is that any parameter of any method or function should be simple class type or built-in type like int . As you may be caught at the end of this explanation, it’s easier to buy a new computer than change the source code of your project(s) according to the rules described above. The ideas described above are also explain why old-time coded C++ projects are typically compiling faster than the C++ projects which created, for instance, last year.
|
|
Chun Pong Lau
|
Oct 15, 2008 - 1:12 AM
|
Dear support, When I drag a docked control bar, there are some cases the whole application will be hold for a period, say, 1-2 mins. During this, I cannot control anything about the application. Is it a known-bug at the library? Regards, Chun Pong
|
|
Technical Support
|
Oct 17, 2008 - 1:20 PM
|
No. You can always compare performance of your application with any of our sample applications. Do you use any heavy operations in timer handlers?
|
|
Pawel Kalinowski
|
Oct 15, 2008 - 12:31 AM
|
Dear Sirs, We have some problems with class derived from CExtNCW <CMDIFrameWnd>: class CMainFrame : public CExtNCW <CMDIFrameWnd>
When we move windows toolbar from it’s default position and dock it to the left or top screen edge and then maximize application window, we can see that this window is not fully maximized as shown in pictures: The gap between window and screen edge has the same width as windows toolbar. This problem occured with following prof-UIS versions: 2.83
2.84 (ExtNcFrame-updated-files-284.zip)
2.84 v2 (ExtNcFrame-updated-files-284-Version-2.zip) Do you know how to solve it?
|
|
Pawel Kalinowski
|
Oct 20, 2008 - 6:23 AM
|
Thanks a lot, e-mail sent. Best regards, Pawel Kalinowski
|
|
Technical Support
|
Oct 20, 2008 - 12:44 PM
|
We have just sent our reply by email.
|
|
Pawel Kalinowski
|
Nov 12, 2008 - 4:07 AM
|
|
|
Technical Support
|
Oct 17, 2008 - 1:19 PM
|
We constantly improve the window non-client area skinning code in Prof-UIS. Very unfortunately, the MSD documentation and most articles you can find on the Interned does not explain how to code100% working skinned windows with maximization/restoring/minimization features. The latest Prof-UIS source code provides even better window skinning: it handles several un-documented Windows messages. Here is the compiled version of the SDI sample application in which this problem has gone:
http://www.prof-uis.com/download/forums/SDI-with-undocumented-NC-messages-284.zip
P.S. You can drop us an e-mail to the support mail box so we will provide you with the latest stable source code download.
|
|
Timothy Anderson
|
Oct 14, 2008 - 10:53 PM
|
I’m trying to track down the UI thread locking up on my application. Here’s a quick debug dump: STACK_TEXT:
0012f2ac 7c827d0b 7c83d236 0000031c 00000000 ntdll!KiFastSystemCallRet
0012f2b0 7c83d236 0000031c 00000000 00000000 ntdll!NtWaitForSingleObject+0xc
0012f2ec 7c83d281 0000031c 00000004 00000001 ntdll!RtlpWaitOnCriticalSection+0x1a3
0012f30c 7c82f20c 7c8877a0 00000000 0012f408 ntdll!RtlEnterCriticalSection+0xa8
0012f340 7c82f336 00000000 00000000 0012f388 ntdll!LdrLockLoaderLock+0x133
0012f3bc 7c82f2a3 00000001 00000001 00000000 ntdll!LdrGetDllHandleEx+0x94
0012f3d8 77e65185 00000001 00000000 0012f440 ntdll!LdrGetDllHandle+0x18
0012f424 77e6528f 0012f440 0012f9dc 0012fa38 kernel32!GetModuleHandleForUnicodeString+0x20
0012f89c 77e65155 00000001 00000002 7ffdfc00 kernel32!BasepGetModuleHandleExW+0x17f
0012f8b4 77e64769 7ffdfc00 00000000 7822716b kernel32!GetModuleHandleW+0x29
0012f8c0 7822716b 781df614 0012f9fc 10010475 kernel32!GetModuleHandleA+0x2d
0012f8cc 10010475 00000000 0012f9dc 0012fa38 mfc80!CDC::GetLayout+0xe [f:\sp\vctools\vc7libs\ship\atlmfc\src\mfc\wingdi.cpp @ 698]
WARNING: Stack unwind information not available. Following frames may be wrong.
00000000 00000000 00000000 00000000 00000000 ProfUIS282m!CExtMemoryDC::__InitMemoryDC+0xa5 I’m trying to remember exactly what I was doing with this but I believe I started up another UI thread in order to have a hovering "cancel" box above our main application with it’s own UI thread running normally. I’m going to keep digging on this, but has anyone seen anything like this before? The main problem is after the cancel box goes away the main application is simply locked up and has to be killed. This unfortunately only happens "every now and then." It’s obviously driving me insane. Any hints would be fabu.
|
|
Technical Support
|
Oct 15, 2008 - 11:31 AM
|
The above call stack gives us very little to understand what is wrong. We can guess that you are using a non-multi-thread library from different threads but the GDI subsystem is not multithreaded.
Besides, please try to remember when this problem appeared for the first time. It is always possible to comment out this and that part of code in order to find out what causes the problem.
|
|
tera tera
|
Oct 14, 2008 - 7:22 PM
|
Hello. I want to make the movement of the focus impossibility to a specific cell.
Please teach a method.
|
|
Technical Support
|
Oct 21, 2008 - 12:58 PM
|
We changed the source code of the CMyMlGrid::FocusSet() virtual method in your project: CPoint CMyMlGrid::FocusSet(
const POINT & ptNewFocus,
bool bEnsureVisibleColumn, // = true
bool bEnsureVisibleRow, // = true
bool bResetSelectionToFocus, // = true
bool bRedraw, // = true
bool * p_bCanceled // = NULL
)
{
ASSERT_VALID( this );
CPoint ptNewFocus2;
ptNewFocus2 = ptNewFocus;
if( ptNewFocus2.y >= 5 )
ptNewFocus2.y = 4;
return CExtGridWnd::FocusSet( ptNewFocus2, bEnsureVisibleColumn, bEnsureVisibleRow, bResetSelectionToFocus, bRedraw, p_bCanceled );
} We also added a _SelectionAreaConvert() virtual method into the CMyMlGrid class. Here is the in-class method declaration: CRect & _SelectionAreaConvert( CRect & rcArea ) const;
Here is the method implementation:
CRect & CMyMlGrid::_SelectionAreaConvert( CRect & rcArea ) const
{
ASSERT_VALID( this );
if( rcArea.top >= 5 )
rcArea.top = 4;
if( rcArea.bottom >= 5 )
rcArea.bottom = 4;
return rcArea;
} Now it seems the grid window works as you want it to.
|
|
Technical Support
|
Oct 15, 2008 - 11:36 AM
|
You should override the CExtGridBaseWnd::FocusSet() virtual method in your CExtGridWnd () -derived class.
CPoint CYourGridWnd::FocusSet(
const POINT & ptNewFocus,
bool bEnsureVisibleColumn, // = true
bool bEnsureVisibleRow, // = true
bool bResetSelectionToFocus, // = true
bool bRedraw, // = true
bool * p_bCanceled // = NULL
)
{
ASSERT_VALID( this );
CPoint ptOldFocus( FocusGet() );
bool bAllowFocusSetting = . . . // compute whether focus can be set to the grid cell at the ptNewFocus location
if( ! bAllowFocusSetting )
return ptOldFocus;
return
PARENT_CLASS_OF_CYourGridWnd_CLASS::FocusSet(
ptNewFocus,
bEnsureVisibleColumn,
bEnsureVisibleRow,
bResetSelectionToFocus,
bRedraw,
p_bCanceled
);
} This virtual method implementation makes particular grid cells unable to receive focus if bAllowFocusSetting is computed as false . Please note you also need to implement your keyboard processing for jumping over the grid cells that cannot receive focus.
|
|
tera tera
|
Oct 17, 2008 - 10:01 PM
|
|
|
tera tera
|
Oct 17, 2008 - 10:17 PM
|
There is the problem else
The movement restrictions of the cell come to be performed when I change __ESIS_STH_NONE in __ESIS_STH_ITEM.
However, there is a problem.
I move a cell to the removable place.
When I push Key and do it, a cell moves to the sixth line.
|