Esempio n. 1
0
        public void SaveRequested()
        {
            if (false == PanelWasMade)
            {
                return;
            }


            if (configPanel == null)
            {
                throw new Exception("no config panel defined");
            }

            BaseDatabase db = CreateDatabase();

            Store(db, KEY_formsize, TextSizeCombo.Text, 0);
            if (MarkupCombo.SelectedItem != null)
            {
                Store(db, KEY_markup, MarkupCombo.SelectedItem.GetType().AssemblyQualifiedName.ToString(), 0);
            }
            System.Drawing.FontConverter fc = new System.Drawing.FontConverter();
            string fontString = (string)fc.ConvertTo(DefaultFont.Font, typeof(string));

            Store(db, KEY_font, fontString, 0);

            db.Dispose();
        }
Esempio n. 2
0
        internal static List <ESRI.ArcGIS.Geometry.IPointCollection> TextToPoints(string input, float offset)
        {
            System.Drawing.FontConverter fc = new System.Drawing.FontConverter();
            float hpos  = 0.0F;
            float vpos  = 0.0F;
            float angle = 0.0F; // 225.0F;
            List <ESRI.ArcGIS.Geometry.IPointCollection> apointList = new List <ESRI.ArcGIS.Geometry.IPointCollection>();

            foreach (char c in input)
            {
                System.Drawing.Drawing2D.GraphicsPath p = GetPath(c.ToString(), hpos + offset, vpos, angle);
                apointList.Add(PathToPoint(p.PathPoints));
            }

            return(apointList);
        }
        public void SaveRequested()
        {
            if (false == PanelWasMade)
                return;

            if (configPanel == null) {
                throw new Exception ("no config panel defined");
            }

            BaseDatabase db = CreateDatabase ();

            Store (db, KEY_formsize, TextSizeCombo.Text, 0);
            if (MarkupCombo.SelectedItem != null) {
                Store (db, KEY_markup, MarkupCombo.SelectedItem.GetType ().AssemblyQualifiedName.ToString (),0);
            }
            System.Drawing.FontConverter fc = new System.Drawing.FontConverter();
            string fontString = (string)fc.ConvertTo(DefaultFont.Font, typeof(string));
            Store (db, KEY_font, fontString, 0);

            db.Dispose();
        }