CXTPControlMarkupLabel capabilities in command bar |
Post Reply |
Author | |
PierreL
Groupie Joined: 01 September 2006 Location: Canada Status: Offline Points: 17 |
Post Options
Thanks(0)
Posted: 02 March 2009 at 9:14pm |
Hello folks,
I've been playing with the various markup features and I like it so far! Good job I must admit I'm having trouble understanding some of the capabilities as I'm new to XAML. It could also be that I'm trying to do something which is not supported? Here's an example of what I'm trying to achieve, maybe someone can help me figure this out? I have a frame that contains a few toolbars. One of these toolbars hosts a CXTPControlMarkupLabel to which I applied some markup. I want it to look like this: (See further down for the markup code) My problem: 1- The Button is not responding to click events as it does in the MarkupPad. For this to work, does the host of such a control need to derive from 'CXTPMarkupContext'? 2- If possible, how do I "connect" this label (using SetDelegate) when my frame does not derive from CXTPMarkupContext? Is there a way to do this so I can respond to events in my frame class? I'd like to display a drop-down list when it is clicked. Thank's for your help, Peter Markup code: <StackPanel Orientation="Horizontal"> <Button> <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="Auto"/> <ColumnDefinition Width="*"/> <ColumnDefinition Width="*"/> <ColumnDefinition Width="*"/> </Grid.ColumnDefinitions> <Image Grid.Column="0" Width="24" Height="24" HorizontalAlignment="Left" VerticalAlignment="Top" Source="1002"/> <TextBlock Grid.Column="1" FontWeight="Bold" Foreground="Navy" Text="Jason Bourne" TextAlignment="Left" VerticalAlignment="Center"/> <TextBlock Grid.Column="2" Margin="8, 0, 8, 0" Foreground="Gray" TextAlignment="Right" VerticalAlignment="Center">(Available: <Hyperlink ToolTip="Call Jason...">+16101234567</Hyperlink>) </TextBlock> <Image Grid.Column="3" Width="11" Height="11" HorizontalAlignment="Right" VerticalAlignment="Center" Source="1003"/> </Grid> </Button> </StackPanel> |
|
Product: Xtreme ToolkitPro version 13.0.0
Platform: Windows XP (32bit) - SP 3 Language: C++ (MFC) |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi,
Sorry, with CommandBars you can only use format features of Markup but can't use its events :(
So there is more difficult path - create standard STATIC with Markup (copy code from our sample) and insert it to toolbar with CXTPControlCustom control type.
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
PierreL
Groupie Joined: 01 September 2006 Location: Canada Status: Offline Points: 17 |
Post Options
Thanks(0)
|
Thanks Oleg,
Maybe in future releases? About the format features of Markup (in regards to my sample), can I change the default look of the markup button from my sample above? More specifically, can I use LinearGradientBrush & GradientStops? I tried but it requires the Page.Resource tag, which I assume is not supported in the CommandBars right? Oh, and which Sample were you referring to in your reply? Thanks again! Peter |
|
Product: Xtreme ToolkitPro version 13.0.0
Platform: Windows XP (32bit) - SP 3 Language: C++ (MFC) |
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
Hi,
I mean \Samples\ToolkitPro\MarkupSample sample and its MarkupStatic file.
Maybe event better to use our CXTPButton with markup inside. Check this sample anyway. :)
|
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |