[mapguide-commits] r4569 -
trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Sat Jan 30 15:04:38 EST 2010
Author: ksgeograf
Date: 2010-01-30 15:04:38 -0500 (Sat, 30 Jan 2010)
New Revision: 4569
Modified:
trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.cs
trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.resx
trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/LineFeatureStyleEditor.cs
Log:
Maestro:
Fixed issue #1254.
Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.cs 2010-01-30 19:32:31 UTC (rev 4568)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.cs 2010-01-30 20:04:38 UTC (rev 4569)
@@ -162,6 +162,7 @@
this.sizeUnitsCombo.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.sizeUnitsCombo.Name = "sizeUnitsCombo";
this.sizeUnitsCombo.ValueMember = "Value";
+ this.sizeUnitsCombo.SelectedIndexChanged += new System.EventHandler(this.sizeUnitsCombo_SelectedIndexChanged);
//
// UnitsTable
//
@@ -188,6 +189,7 @@
this.sizeContextCombo.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.sizeContextCombo.Name = "sizeContextCombo";
this.sizeContextCombo.ValueMember = "Value";
+ this.sizeContextCombo.SelectedIndexChanged += new System.EventHandler(this.sizeContextCombo_SelectedIndexChanged);
//
// SizeContextTable
//
@@ -290,9 +292,10 @@
try
{
- if (m_item == null)
+ m_inUpdate = true;
+
+ if (m_item == null)
{
- m_inUpdate = true;
fillStyleEditor.displayFill.Checked = false;
lineStyleEditor.displayLine.Checked = false;
return;
@@ -313,13 +316,12 @@
if (m_item.Stroke != null)
{
sizeUnitsCombo.SelectedValue = m_item.Stroke.Unit.ToString();
- //sizeContextCombo.SelectedValue = st.??;
+ sizeContextCombo.SelectedValue = m_item.Stroke.SizeContext.ToString();
if (m_item.Stroke.ColorAsHTML != null)
lineStyleEditor.colorCombo.CurrentColor = m_item.Stroke.Color;
lineStyleEditor.fillCombo.SelectedIndex = lineStyleEditor.fillCombo.FindString(m_item.Stroke.LineStyle);
lineStyleEditor.thicknessCombo.Text = m_item.Stroke.Thickness;
}
- m_inUpdate = true;
previewPicture.Refresh();
}
@@ -498,5 +500,21 @@
m_inUpdate = false;
}
}
+
+ private void sizeContextCombo_SelectedIndexChanged(object sender, EventArgs e)
+ {
+ if (m_inUpdate || m_item.Stroke == null)
+ return;
+
+ m_item.Stroke.SizeContext = (OSGeo.MapGuide.MaestroAPI.SizeContextType)Enum.Parse(typeof(OSGeo.MapGuide.MaestroAPI.SizeContextType), (string)sizeContextCombo.SelectedValue);
+ }
+
+ private void sizeUnitsCombo_SelectedIndexChanged(object sender, EventArgs e)
+ {
+ if (m_inUpdate || m_item.Stroke == null)
+ return;
+
+ m_item.Stroke.Unit = (OSGeo.MapGuide.MaestroAPI.LengthUnitType)Enum.Parse(typeof(OSGeo.MapGuide.MaestroAPI.LengthUnitType), (string)sizeUnitsCombo.SelectedValue);
+ }
}
}
Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.resx
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.resx 2010-01-30 19:32:31 UTC (rev 4568)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/AreaFeatureStyleEditor.resx 2010-01-30 20:04:38 UTC (rev 4569)
@@ -136,7 +136,7 @@
<value>fillStyleEditor</value>
</data>
<data name=">>fillStyleEditor.Type" xml:space="preserve">
- <value>OSGeo.MapGuide.Maestro.ResourceEditors.GeometryStyleEditors.FillStyleEditor, OSGeo.MapGuide.Maestro.ResourceEditors, Version=1.1.0.4358, Culture=neutral, PublicKeyToken=null</value>
+ <value>OSGeo.MapGuide.Maestro.ResourceEditors.GeometryStyleEditors.FillStyleEditor, OSGeo.MapGuide.Maestro.ResourceEditors, Version=1.1.0.4480, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>fillStyleEditor.Parent" xml:space="preserve">
<value>groupBox2</value>
@@ -160,7 +160,7 @@
<value>lineStyleEditor</value>
</data>
<data name=">>lineStyleEditor.Type" xml:space="preserve">
- <value>OSGeo.MapGuide.Maestro.ResourceEditors.GeometryStyleEditors.LineStyleEditor, OSGeo.MapGuide.Maestro.ResourceEditors, Version=1.1.0.4358, Culture=neutral, PublicKeyToken=null</value>
+ <value>OSGeo.MapGuide.Maestro.ResourceEditors.GeometryStyleEditors.LineStyleEditor, OSGeo.MapGuide.Maestro.ResourceEditors, Version=1.1.0.4480, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>lineStyleEditor.Parent" xml:space="preserve">
<value>groupBox1</value>
@@ -321,18 +321,6 @@
<data name="previewGroup.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Top, Left, Right</value>
</data>
- <data name="previewPicture.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
- <value>Top, Left, Right</value>
- </data>
- <data name="previewPicture.Location" type="System.Drawing.Point, System.Drawing">
- <value>8, 16</value>
- </data>
- <data name="previewPicture.Size" type="System.Drawing.Size, System.Drawing">
- <value>282, 24</value>
- </data>
- <data name="previewPicture.TabIndex" type="System.Int32, mscorlib">
- <value>0</value>
- </data>
<data name=">>previewPicture.Name" xml:space="preserve">
<value>previewPicture</value>
</data>
@@ -369,6 +357,30 @@
<data name=">>previewGroup.ZOrder" xml:space="preserve">
<value>0</value>
</data>
+ <data name="previewPicture.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
+ <value>Top, Left, Right</value>
+ </data>
+ <data name="previewPicture.Location" type="System.Drawing.Point, System.Drawing">
+ <value>8, 16</value>
+ </data>
+ <data name="previewPicture.Size" type="System.Drawing.Size, System.Drawing">
+ <value>282, 24</value>
+ </data>
+ <data name="previewPicture.TabIndex" type="System.Int32, mscorlib">
+ <value>0</value>
+ </data>
+ <data name=">>previewPicture.Name" xml:space="preserve">
+ <value>previewPicture</value>
+ </data>
+ <data name=">>previewPicture.Type" xml:space="preserve">
+ <value>System.Windows.Forms.PictureBox, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+ </data>
+ <data name=">>previewPicture.Parent" xml:space="preserve">
+ <value>previewGroup</value>
+ </data>
+ <data name=">>previewPicture.ZOrder" xml:space="preserve">
+ <value>0</value>
+ </data>
<metadata name="ComboBoxDataSet.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
Modified: trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/LineFeatureStyleEditor.cs
===================================================================
--- trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/LineFeatureStyleEditor.cs 2010-01-30 19:32:31 UTC (rev 4568)
+++ trunk/Tools/Maestro/Maestro/ResourceEditors/GeometryStyleEditors/LineFeatureStyleEditor.cs 2010-01-30 20:04:38 UTC (rev 4569)
@@ -139,7 +139,7 @@
if (st != null)
{
sizeUnitsCombo.SelectedValue = st.Unit.ToString();
- //sizeContextCombo.SelectedValue = st.??;
+ sizeContextCombo.SelectedValue = st.SizeContext.ToString();
if (st.ColorAsHTML == null)
lineStyleEditor.colorCombo.CurrentColor = Color.Black;
else
@@ -463,8 +463,10 @@
{
if (m_inUpdate)
return;
- //TODO: Where does this go?
- if (Changed != null)
+ this.CurrentStrokeType.SizeContext = (OSGeo.MapGuide.MaestroAPI.SizeContextType)Enum.Parse(typeof(OSGeo.MapGuide.MaestroAPI.SizeContextType), (string)sizeContextCombo.SelectedValue);
+ previewPicture.Refresh();
+ lineStyles.Refresh();
+ if (Changed != null)
Changed(this, new EventArgs());
}
More information about the mapguide-commits
mailing list