예제 #1
0
 public EsriController(GISServer esriServer)
     : base(esriServer)
 {
     if (string.IsNullOrEmpty(esriServer.ServletPath))
     {
         esriServer.ServletPath = "servlet/com.esri.esrimap.Esrimap";
     }
 }
예제 #2
0
 public FontWindow(GISServer.Core.Client.Symbols.Font initialfont)
 {
     InitializeComponent();
     fontsymbol = new GISServer.Core.Client.Symbols.Font
     {
         Size = initialfont.Size,
         Family = initialfont.Family,
         Weight = "normal",
         Decoration = "none",
         Style = "style"
     };
     Update();
 }
        private void UpdateUI(GISServer.Core.Client.Symbols.SimpleLineSymbol simplemarkersymbol)
        {
            txttype.Text = simplemarkersymbol.Type;
            txtwidth.Text = simplemarkersymbol.Width.ToString();

            var colorbrush = new SolidColorBrush
            {
                Color = new System.Windows.Media.Color
                {
                    R = simplemarkersymbol.Color[0],
                    G = simplemarkersymbol.Color[1],
                    B = simplemarkersymbol.Color[2],
                    A = simplemarkersymbol.Color[3]
                }
            };
            reccolor.Fill = colorbrush;

            switch (simplemarkersymbol.Style)
            {
                case "esriSLSDash":
                    cbxstyle.SelectedIndex = 0;
                    break;
                case "esriSLSDashDotDot":
                    cbxstyle.SelectedIndex = 1;
                    break;
                case "esriSLSDot":
                    cbxstyle.SelectedIndex = 2;
                    break;
                case "esriSLSNull":
                    cbxstyle.SelectedIndex = 3;
                    break;
                case "esriSLSSolid":
                    cbxstyle.SelectedIndex = 4;
                    break;
                default:
                    break;
            }
        }
        private void UpdateUI(GISServer.Core.Client.Symbols.PictureFillSymbol picturemarkersymbol)
        {
            txttype.Text = picturemarkersymbol.Type;
            txturl.Text = picturemarkersymbol.Url;
            txtcontenttype.Text = picturemarkersymbol.ContentType;

            txtwidth.Text = picturemarkersymbol.Width.ToString();
            txtheight.Text = picturemarkersymbol.Height.ToString();
            txtangle.Text = picturemarkersymbol.Angle.ToString();
            txtxoffset.Text = picturemarkersymbol.Xoffset.ToString();
            txtyoffset.Text = picturemarkersymbol.Yoffset.ToString();
            txtxscale.Text = picturemarkersymbol.Xscale.ToString();
            txtyscale.Text = picturemarkersymbol.Yscale.ToString();

            var colorbrush = new SolidColorBrush
            {
                Color = new System.Windows.Media.Color
                {
                    R = picturemarkersymbol.Color[0],
                    G = picturemarkersymbol.Color[1],
                    B = picturemarkersymbol.Color[2],
                    A = picturemarkersymbol.Color[3]
                }
            };
            reccolor.Fill = colorbrush;
        }
예제 #5
0
        private void Update(GISServer.Core.Client.Symbols.Font fontsymbol)
        {
            txtfont.FontSize = fontsymbol.Size;

            switch (fontsymbol.Weight)
            {
                case "bold":
                    txtfont.FontWeight = FontWeights.Bold;
                    break;
                case "bolder":
                    txtfont.FontWeight = FontWeights.ExtraBold;
                    break;
                case "lighter":
                    txtfont.FontWeight = FontWeights.Light;
                    break;
                case "normal":
                    txtfont.FontWeight = FontWeights.Normal;
                    break;

                default:
                    break;
            }

            switch (fontsymbol.Style)
            {
                case "italic":
                    txtfont.FontStyle = FontStyles.Italic;
                    break;
                case "normal":
                    txtfont.FontStyle = FontStyles.Normal;
                    break;
                case "oblique": //need to fix the oblique
                    txtfont.FontStyle = FontStyles.Italic;
                    break;

                default:
                    break;
            }
            switch (fontsymbol.Decoration)
            {
                case "line-through":
                    txtfont.TextDecorations = TextDecorations.Underline;
                    break;
                case "underline":
                    txtfont.TextDecorations = TextDecorations.Underline;
                    break;
                case "none": //need to fix the oblique
                    txtfont.TextDecorations = null;
                    break;

                default:
                    break;
            }

            txtfont.FontFamily = new FontFamily(fontsymbol.Family);
        }
예제 #6
0
 public OGCController(GISServer server) : base(server) { }
예제 #7
0
 public EsriRESTController(GISServer esriServer)
     : base(esriServer)
 {
     _zoomType = ZOOM_TYPE.PERCENT;
     if (string.IsNullOrEmpty(Server.ServletPath)) Server.ServletPath = "arcgis/rest/services";
 }
        private void UpdateUI(GISServer.Core.Client.Symbols.SimpleFillSymbol simplemarkersymbol)
        {
            txttype.Text = simplemarkersymbol.Type;

            var colorbrush = new SolidColorBrush
            {
                Color = new System.Windows.Media.Color
                {
                    R = simplemarkersymbol.Color[0],
                    G = simplemarkersymbol.Color[1],
                    B = simplemarkersymbol.Color[2],
                    A = simplemarkersymbol.Color[3]
                }
            };
            reccolor.Fill = colorbrush;

            switch (simplemarkersymbol.Style)
            {
                case "esriSFSBackwardDiagonal":
                    cbxstyle.SelectedIndex = 0;
                    break;
                case "esriSFSCross":
                    cbxstyle.SelectedIndex = 1;
                    break;
                case "esriSFSDiagonalCross":
                    cbxstyle.SelectedIndex = 2;
                    break;
                case "esriSFSForwardDiagonal":
                    cbxstyle.SelectedIndex = 3;
                    break;
                case "esriSFSHorizontal":
                    cbxstyle.SelectedIndex = 4;
                    break;
                case "esriSFSNull":
                    cbxstyle.SelectedIndex = 5;
                    break;
                case "esriSFSSolid":
                    cbxstyle.SelectedIndex = 6;
                    break;
                case "esriSFSVertical":
                    cbxstyle.SelectedIndex = 7;
                    break;
                default:
                    break;
            }
        }
        private void UpdateUI(GISServer.Core.Client.Symbols.SimpleMarkerSymbol simplemarkersymbol)
        {
            txttype.Text = simplemarkersymbol.Type;
            txtsize.Text = simplemarkersymbol.Size.ToString();
            txtangle.Text = simplemarkersymbol.Angle.ToString();
            txtxoffset.Text = simplemarkersymbol.Xoffset.ToString();
            txtyoffset.Text = simplemarkersymbol.Yoffset.ToString();

            var colorbrush = new SolidColorBrush
            {
                Color = new System.Windows.Media.Color
                {
                    R = simplemarkersymbol.Color[0],
                    G = simplemarkersymbol.Color[1],
                    B = simplemarkersymbol.Color[2],
                    A = simplemarkersymbol.Color[3]
                }
            };
            reccolor.Fill = colorbrush;

            var bordercolorbrush = new SolidColorBrush
            {
                Color = new System.Windows.Media.Color
                {
                    R = simplemarkersymbol.Outline.Color[0],
                    G = simplemarkersymbol.Outline.Color[1],
                    B = simplemarkersymbol.Outline.Color[2],
                    A = simplemarkersymbol.Outline.Color[3]
                }
            };
            boroutline.BorderBrush = bordercolorbrush;
            boroutline.BorderThickness = new Thickness(simplemarkersymbol.Outline.Width);

            switch (simplemarkersymbol.Style)
            {
                case "esriSMSCircle":
                    cbxstyle.SelectedIndex = 0;
                    break;
                case "esriSMSCross":
                    cbxstyle.SelectedIndex = 1;
                    break;
                case "esriSMSDiamond":
                    cbxstyle.SelectedIndex = 2;
                    break;
                case "esriSMSSquare":
                    cbxstyle.SelectedIndex = 3;
                    break;
                case "esriSMSX":
                    cbxstyle.SelectedIndex = 4;
                    break;
                default:
                    break;
            }
        }