ScaleVisibility bug?

3 posts, 1 answers
  1. Rieni De Rijke
    Rieni De Rijke avatar
    170 posts
    Member since:
    Mar 2010

    Posted 13 Oct 2011 Link to this post

    On our RadMap we have some layers. The layers contain some objects/mapItems.
    All these objects have tooltips and when moving the mouse over an object the cursor changes to a hand-cursor and the ToolTip shows..

    This works fine.
    But...
    When ScaleVisibility = "Visible" this won't work for objects which are placed in the bottom of the map. Or you can say: it doesn't work for objects lying on or under the same height as the ScaleBar.
    When ScaleVisibility = "Collapsed" all the objects are working OK.
    Could this be a bug in the z-index of the Scalebar?

    For your information:
         <DataTemplate.Triggers>
                <Trigger SourceName="pin" Property="IsMouseOver" Value="true">
                    <Setter Property="Cursor" Value="Hand"/>
                </Trigger>
            </DataTemplate.Triggers>
  2. Answer
    Andrey
    Admin
    Andrey avatar
    1681 posts

    Posted 18 Oct 2011 Link to this post

    Hello Rieni De Rijke,

    The place within which is about 40 pixels of the bottom is used for standard controls of the RadMap. It is transparent for standard theme, but it doesn't have transparent colors for other themes. So, in any case it handles mouse events.
    You can use custom MouseLocationIndicator and MapScale to avoid this problem. The sample code is below.
    <Window x:Class="DragDropPinPoints.MainWindow"
            Title="MainWindow" Height="600" Width="800">
        <Grid>
            <telerik:RadMap x:Name="RadMap1"
                            MouseLocationIndicatorVisibility="Collapsed"
                            ScaleVisibility="Collapsed">
                <telerik:RadMap.Provider>
                    <telerik:OpenStreetMapProvider />
                </telerik:RadMap.Provider>
                <telerik:InformationLayer x:Name="informationLayer" />
            </telerik:RadMap>
            <telerik:MapScale MapControl="{Binding ElementName=RadMap1}"
                              HorizontalAlignment="Right"
                              VerticalAlignment="Bottom"
                              Margin="20" />
            <telerik:MapMouseLocationIndicator MapControl="{Binding ElementName=RadMap1}"
                                               Margin="20"
                                               HorizontalAlignment="Left"
                                               VerticalAlignment="Bottom"/>
        </Grid>
    </Window>

    Best wishes,
    Andrey Murzov
    the Telerik team

    Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

  3. UI for WPF is Visual Studio 2017 Ready
  4. Rieni De Rijke
    Rieni De Rijke avatar
    170 posts
    Member since:
    Mar 2010

    Posted 18 Oct 2011 Link to this post

    It works!
    Thank you very much!
Back to Top