<>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:“Table Normal”;
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:“Calibri”,“sans-serif”;
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:“Times New Roman”;
mso-bidi-theme-font:minor-bidi;
mso-fareast-language:EN-US;}
<![endif]–><!–[if gte mso 9]><>
<w:Word>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:Trackatting/>
<w:HyphenationZone>21</w:HyphenationZone>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfInvalid>false</w:SaveIfInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DonotPromoteQF/>
<w:LidThemeOther>PL</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplex>X-NONE</w:LidThemeComplex>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndark/>
<w:EnableKerning/>
<w:DontFlipMirrorIndents/>
<w:OverrideTableStyleHps/>
</w:Compatibility>
<m:mathPr>
<m:mathFont m:val=“Cambria Math”/>
<m:brkBin m:val=“before”/>
<m:brkBinSub m:val="–"/>
<m:smallFrac m:val=“off”/>
<m:dispDef/>
<m:lMargin m:val=“0”/>
<m:rMargin m:val=“0”/>
<m:defJc m:val=“centerGroup”/>
<m:wrapIndent m:val=“1440”/>
<m:intLim m:val=“subSup”/>
<m:naryLim m:val=“undOvr”/>
</m:mathPr></w:Word>
</><![endif]–><!–[if gte mso 10]>
<>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:“Table Normal”;
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:“Calibri”,“sans-serif”;
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:“Times New Roman”;
mso-bidi-theme-font:minor-bidi;
mso-fareast-language:EN-US;}
<![endif]–><!–[if gte mso 9]><>
<w:Word>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:TrackMoves/>
<w:Trackatting/>
<w:HyphenationZone>21</w:HyphenationZone>
<w:PunctuationKerning/>
<w:ValidateAgainstSchemas/>
<w:SaveIfInvalid>false</w:SaveIfInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:DonotPromoteQF/>
<w:LidThemeOther>PL</w:LidThemeOther>
<w:LidThemeAsian>X-NONE</w:LidThemeAsian>
<w:LidThemeComplex>X-NONE</w:LidThemeComplex>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:DontGrowAutofit/>
<w:SplitPgBreakAndark/>
<w:EnableKerning/>
<w:DontFlipMirrorIndents/>
<w:OverrideTableStyleHps/>
</w:Compatibility>
<m:mathPr>
<m:mathFont m:val=“Cambria Math”/>
<m:brkBin m:val=“before”/>
<m:brkBinSub m:val="–"/>
<m:smallFrac m:val=“off”/>
<m:dispDef/>
<m:lMargin m:val=“0”/>
<m:rMargin m:val=“0”/>
<m:defJc m:val=“centerGroup”/>
<m:wrapIndent m:val=“1440”/>
<m:intLim m:val=“subSup”/>
<m:naryLim m:val=“undOvr”/>
</m:mathPr></w:Word>
</><![endif]–><!–[if gte mso 10]>
<>
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:“Table Normal”;
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-priority:99;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:11.0pt;
font-family:“Calibri”,“sans-serif”;
mso-ascii-font-family:Calibri;
mso-ascii-theme-font:minor-latin;
mso-hansi-font-family:Calibri;
mso-hansi-theme-font:minor-latin;
mso-bidi-font-family:“Times New Roman”;
mso-bidi-theme-font:minor-bidi;
mso-fareast-language:EN-US;}
<![endif]–>
Hi
I’m trying to convert an application using GoDiagram (Win) into Silverlight one and having some issues. The win app is able to show a number of points (represented as icons), move them in any place of the Diagram and keeps the size of the icons unchanged regardless of the current document scale (when document scale changes the app changes the size of the Icon so visually the size stays unchanged). I noticed that in goXam I have no possibility to move object (Icon) in a place I want. When diagram is zoomed in I can move the object only into a specific place – it looks like there is an invisible grid or something…. This probably is the causes of another issues:
1) After changing the size of Icon (in response to document scale change) it is sometimes obscured
2) Selection doesn’t reflect the actual size of the Icon
<span style=“font-size: 11pt; font-family: “Calibri”,“sans-serif”;” lang=“EN-US”><p =“MsoListParagraph”>
It is implemented in the following way:
void PanelViewportBoundsChanged(object sender, RoutedPropertyChangedEventArgs<Rect> e)
{
foreach (var visualObject in this.Model.VisualObjectList)
{
if (visualObject is Element)
{
((Element)visualObject).CurrentScale = this.diagram1.Panel.Scale; //notify visual Element that the scale has changed
}
}
}
public class Element
{
public double CurrentScale
{
get { return this._currentScale; }
set
{
if (this._currentScale != value)
{
this._currentScale = value;
this.OnPropertyChanged("Width");
this.OnPropertyChanged("Height");
}
}
}
public double Width
{
get { return this._width / this._currentScale; }
}
public double Height
{
get { return this._height / this._currentScale; }
}
public Brush Fill
{
get
{
return new ImageBrush { ImageSource = new BitmapImage(new Uri(this.ImageLink)) };
}
}
}
XAML:
<ResourceDictionary
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:go="clr-namespace:Northwoods.GoXam;assembly=Northwoods.GoSilverlight">
<DataTemplate x:Key="SelectionAdornentDataTemplate">
<Path go:NodePanel.Figure="None" Stroke="Green" StrokeThickness="{Binding Path=Data.SelectionThickness}" go:Part.Selectable="False" UseLayoutRounding="False"/>
</DataTemplate>
<go:DataTemplateDictionary x:Key="VisualObjectTemplates">
<DataTemplate x:Key="ElementDataTemplate">
<Path x:Name="Shape" go:NodePanel.Figure="Rectangle"
go:Part.SelectionAdorned="True"
UseLayoutRounding ="False"
go:Node.Location="{Binding Path=Data.Location}"
go:Part.SelectionAdornmentTemplate="{StaticResource SelectionAdornentDataTemplate}"
go:Part.Editable="True"
go:Part.Movable="True"
go:Part.Deletable="False"
Fill="{Binding Path=Data.Fill}"
Width="{Binding Path=Data.Width}"
Height="{Binding Path=Data.Height}"
>
</Path>
</DataTemplate>
</go:DataTemplateDictionary>
</ResourceDictionary>
Can anyone help me? How can I disable the ‘grid’ effect?
Thanks
Marcin