Professional UI Solutions
Site Map   /  Register
 
 

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.

Forums » Prof-UIS Tech Support » CExtGridCellInplaceSlider and tool tip Collapse All
Subject Author Date
Emmanuel V. Nov 10, 2011 - 7:34 AM

Hello,


Is there a way to add a tooltip in CExtGridCellInplaceSlider ? I’m using this slider inside a PropertyGrid, and if we want to set a particular value, it’s not possible.


Is there also a "buddy to edit" that can be linked to this CExtGridCellInplaceSlider ?


Thanks.

Emmanuel V. Nov 24, 2011 - 1:38 AM

We upgraded to ProfUIS v2.92, but it seems that CExtGridCell::ContentTipSet() is not working in a CExtPropertyGrid, which directly inherits from  CWnd, not CExtGridWnd. Can you confirm, or we done something wrong ?


Thanks.

Technical Support Nov 24, 2011 - 8:41 AM

First of all, you should make tree grids inside the property grid control displaying content tips. Please invoke the following code during property grid initialization:

CExtPropertyGridCtrl & _PGC = . . .
 CExtPropertyGridWndCategorized * pPgwCategorized =
         STATIC_DOWNCAST( CExtPropertyGridWndCategorized, _PGC.GetChildByRTC( RUNTIME_CLASS(CExtPropertyGridWndCategorized) ) );
     ASSERT_VALID( pPgwCategorized );
     pPgwCategorized->HoverEventsSet( true, false );
     pPgwCategorized->AdvModifyStyle( __EGWS_ADV_CELL_CONTENT_TIPS_INNER );
 CExtPropertyGridWndSorted * pPgwSorted =
         STATIC_DOWNCAST( CExtPropertyGridWndSorted, _PGC.GetChildByRTC( RUNTIME_CLASS(CExtPropertyGridWndSorted) ) );
     ASSERT_VALID( pPgwSorted );
     pPgwSorted->HoverEventsSet( true, false );
     pPgwSorted->AdvModifyStyle( __EGWS_ADV_CELL_CONTENT_TIPS_INNER );
 

Second, assign content tip before assigning grid cell to property value. Here is how we did this in the PropertyGrod sample project:
CExtPropertyValue * pValSlider = new CExtPropertyValue( _T("Slider") );
     pValSlider->NameSet( _T("Slider control") );
     pValSlider->DescriptionSet( _T("Slider control.") );
 CExtGridCellInplaceSlider * pCellInplaceSlider =
         STATIC_DOWNCAST(
             CExtGridCellInplaceSlider,
             pValSlider->ValueDefaultGetByRTC(
                 RUNTIME_CLASS( CExtGridCellInplaceSlider )
                 )
             );
     pCellInplaceSlider->ScrollTotalRangeSet( 100 );
     //pCellInplaceSlider->ScrollPageSizeSet( 20 );
     pCellInplaceSlider->ScrollPosSet( 50 );
     pCellInplaceSlider->ContentTipSet( _T("CExtGridCellInplaceSlider") );
     pValSlider->ValueActiveFromDefault();
     pCategoryMisc->ItemInsert(
         pValSlider
         );
 

Technical Support Nov 11, 2011 - 5:13 AM

Grid cells in Prof-UIS 2.91 and older support a tooltip and a content expanding window. But this is supported only for grid cells with not fully visible inner cell parts. In Prof-UIS 2.92 and later all grid cells support new HTML-enabled content tips (CExtGridCell::ContentTipSet()). Content tips are displayed near grid cells just when the mouse pointer is over cell area. It’s not important whether cell inner parts are completely visible.

The drid control is not a dialog replacement. The "buddy to edit" is not an applicable feature.