public AboutMonoDevelopTabPage ()
		{
			BorderWidth = 0;

			var aboutFile = BrandingService.GetFile ("AboutImage.png");
			if (aboutFile != null)
				imageSep = Xwt.Drawing.Image.FromFile (aboutFile);
			else
				imageSep = Xwt.Drawing.Image.FromResource ("AboutImage.png");

			PackStart (new ImageView (imageSep), false, false, 0);

			Xwt.VBox infoBox = new Xwt.VBox ();
			Xwt.FrameBox mbox = new Xwt.FrameBox (infoBox);

			infoBox.Spacing = 6;
			infoBox.Margin = 12;
			PackStart (mbox.ToGtkWidget (), false, false, 0);

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Version"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			infoBox.PackStart (new Xwt.Label () {
				Text = IdeVersionInfo.MonoDevelopVersion,
				MarginLeft = 12
			});

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("License"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Released under the GNU Lesser General Public License."),
				MarginLeft = 12
			});

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Copyright"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			var cbox = new Xwt.HBox () {
				Spacing = 0,
				MarginLeft = 12
			};
			cbox.PackStart (new Xwt.Label ("© 2011-" + DateTime.Now.Year + " "));
			cbox.PackStart (new Xwt.LinkLabel () {
				Text = string.Format ("Xamarin Inc."),
				Uri = new Uri ("http://www.xamarin.com")
			});
			infoBox.PackStart (cbox);
			infoBox.PackStart (new Xwt.Label () {
				Text = "© 2004-" + DateTime.Now.Year + " MonoDevelop contributors",
				MarginLeft = 12
			});

			this.ShowAll ();
		}
        public AboutMonoDevelopTabPage()
        {
            BorderWidth = 0;

            var aboutFile = BrandingService.GetFile("AboutImage.png");

            if (aboutFile != null)
            {
                imageSep = Xwt.Drawing.Image.FromFile(aboutFile);
            }
            else
            {
                imageSep = Xwt.Drawing.Image.FromResource("AboutImage.png");
            }

            PackStart(new ImageView(imageSep), false, false, 0);

            Xwt.VBox     infoBox = new Xwt.VBox();
            Xwt.FrameBox mbox    = new Xwt.FrameBox(infoBox);

            infoBox.Spacing = 6;
            infoBox.Margin  = 12;
            PackStart(mbox.ToGtkWidget(), false, false, 0);

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("Version"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = IdeVersionInfo.MonoDevelopVersion,
                MarginLeft = 12
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("License"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = GettextCatalog.GetString("Released under the GNU Lesser General Public License."),
                MarginLeft = 12
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("Copyright"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            var cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };

            cbox.PackStart(new Xwt.Label("© 2011-" + DateTime.Now.Year + " "));
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("Xamarin Inc."),
                Uri  = new Uri("http://www.xamarin.com")
            });
            infoBox.PackStart(cbox);
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = "© 2004-" + DateTime.Now.Year + " MonoDevelop contributors",
                MarginLeft = 12
            });

            cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };
            cbox.PackStart(new Xwt.Label("Some icons by "));
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("Yusuke Kamiyamane"),
                Uri  = new Uri("http://p.yusukekamiyamane.com")
            });

            infoBox.PackStart(cbox);

            cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };
            cbox.PackStart(new Xwt.Label("Some icons from the "));
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("Silk icon set"),
                Uri  = new Uri("http://www.famfamfam.com/")
            });
            infoBox.PackStart(cbox);

            this.ShowAll();
        }
		public AboutMonoDevelopTabPage ()
		{
			BorderWidth = 0;

			using (var stream = BrandingService.GetStream ("AboutImage.png", true))
				imageSep = new Pixbuf (stream);
			PackStart (new Gtk.Image (imageSep), false, false, 0);

			Xwt.VBox infoBox = new Xwt.VBox ();
			Xwt.FrameBox mbox = new Xwt.FrameBox (infoBox);

			infoBox.Spacing = 6;
			infoBox.Margin = 12;
			PackStart (mbox.ToGtkWidget (), false, false, 0);

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Version"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			infoBox.PackStart (new Xwt.Label () {
				Text = IdeVersionInfo.MonoDevelopVersion,
				MarginLeft = 12
			});

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("License"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Released under the GNU Lesser General Public License."),
				MarginLeft = 12
			});

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Copyright"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			var cbox = new Xwt.HBox () {
				Spacing = 0,
				MarginLeft = 12
			};
			cbox.PackStart (new Xwt.Label ("© 2011-2013 "));
			cbox.PackStart (new Xwt.LinkLabel () {
				Text = string.Format ("Xamarin Inc."),
				Uri = new Uri ("http://www.xamarin.com")
			});
			infoBox.PackStart (cbox);
			infoBox.PackStart (new Xwt.Label () {
				Text = "© 2004-2013 MonoDevelop contributors",
				MarginLeft = 12
			});

			cbox = new Xwt.HBox () {
				Spacing = 0,
				MarginLeft = 12
			};
			cbox.PackStart (new Xwt.Label ("Some icons by "));
			cbox.PackStart (new Xwt.LinkLabel () {
				Text = string.Format ("Yusuke Kamiyamane"),
				Uri = new Uri ("http://p.yusukekamiyamane.com")
			});

			infoBox.PackStart (cbox);

			cbox = new Xwt.HBox () {
				Spacing = 0,
				MarginLeft = 12
			};
			cbox.PackStart (new Xwt.Label ("Some icons from the "));
			cbox.PackStart (new Xwt.LinkLabel () {
				Text = string.Format ("Silk icon set"),
				Uri = new Uri ("http://www.famfamfam.com/")
			});
			infoBox.PackStart (cbox);

			this.ShowAll ();
		}
        public AboutMonoDevelopTabPage()
        {
            BorderWidth = 0;

            var aboutFile = BrandingService.GetFile(AboutDialogImage.Name);

            if (aboutFile != null)
            {
                imageSep = Xwt.Drawing.Image.FromFile(aboutFile);
            }
            else
            {
                imageSep = Xwt.Drawing.Image.FromResource(AboutDialogImage.Name);
            }

            var iv = new ImageView(imageSep);

            iv.SetCommonAccessibilityAttributes("AboutImage", BrandingService.ApplicationLongName, "");
            PackStart(iv, false, false, 0);

            Xwt.VBox     infoBox = new Xwt.VBox();
            Xwt.FrameBox mbox    = new Xwt.FrameBox(infoBox);

            infoBox.Spacing = 6;
            infoBox.Margin  = 12;
            PackStart(mbox.ToGtkWidget(), false, false, 0);

            infoBox.PackStart(new Xwt.Label()
            {
                Markup    = string.Format("<b>{0}</b>", GettextCatalog.GetString("Version")),
                MarginTop = 6,
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = IdeVersionInfo.MonoDevelopVersion,
                MarginLeft = 12
            });

            if (BrandingService.LicenseTermsUrl != null)
            {
                infoBox.PackStart(new Xwt.Label()
                {
                    Markup    = string.Format("<b>{0}</b>", GettextCatalog.GetString("License")),
                    MarginTop = 6,
                });

                var linkLabel = new Xwt.Label {
                    Markup     = "<span underline='true'>License Terms</span>",
                    Cursor     = Xwt.CursorType.Hand,
                    MarginLeft = 12
                };
                if (IdeTheme.UserInterfaceTheme == Theme.Light)
                {
                    linkLabel.Markup = string.Format("<span color='#5C2D91'>{0}</span>", linkLabel.Markup);
                }

                linkLabel.ButtonReleased += (sender, e) => DesktopService.ShowUrl(BrandingService.LicenseTermsUrl);
                infoBox.PackStart(linkLabel);

                if (BrandingService.PrivacyStatementUrl != null)
                {
                    linkLabel = new Xwt.Label {
                        Markup     = string.Format("<span underline='true'>{0}</span>", GettextCatalog.GetString("Privacy Statement")),
                        Cursor     = Xwt.CursorType.Hand,
                        MarginLeft = 12
                    };

                    if (IdeTheme.UserInterfaceTheme == Theme.Light)
                    {
                        linkLabel.Markup = string.Format("<span color='#5C2D91'>{0}</span>", linkLabel.Markup);
                    }

                    linkLabel.ButtonReleased += (sender, e) => DesktopService.ShowUrl(BrandingService.PrivacyStatementUrl);
                    infoBox.PackStart(linkLabel);
                }
            }

            infoBox.PackStart(new Xwt.Label()
            {
                Markup    = string.Format("<b>{0}</b>", GettextCatalog.GetString("Copyright")),
                MarginTop = 6,
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Text       = (DateTime.Now.Year == 2016 ? "© 2016" : "© 2016–" + DateTime.Now.Year) + " Microsoft Corp.",
                MarginLeft = 12
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = "© 2004–" + DateTime.Now.Year + " Xamarin Inc.",
                MarginLeft = 12
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = "© 2004–" + DateTime.Now.Year + " MonoDevelop contributors",
                MarginLeft = 12
            });

            this.ShowAll();
        }
Esempio n. 5
0
        public AboutMonoDevelopTabPage()
        {
            BorderWidth = 0;

            var aboutFile = BrandingService.GetFile(AboutDialogImage.Name);

            if (aboutFile != null)
            {
                imageSep = Xwt.Drawing.Image.FromFile(aboutFile);
            }
            else
            {
                imageSep = Xwt.Drawing.Image.FromResource(AboutDialogImage.Name);
            }

            PackStart(new ImageView(imageSep), false, false, 0);

            Xwt.VBox     infoBox = new Xwt.VBox();
            Xwt.FrameBox mbox    = new Xwt.FrameBox(infoBox);

            infoBox.Spacing = 6;
            infoBox.Margin  = 12;
            PackStart(mbox.ToGtkWidget(), false, false, 0);

            infoBox.PackStart(new Xwt.Label()
            {
                Markup    = string.Format("<b>{0}</b>", GettextCatalog.GetString("Version")),
                MarginTop = 6,
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = IdeVersionInfo.MonoDevelopVersion,
                MarginLeft = 12
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Markup    = string.Format("<b>{0}</b>", GettextCatalog.GetString("License")),
                MarginTop = 6,
            });
            var cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };
            var linkLabel = new Xwt.Label {
                Markup = "<span underline='true'>License Terms</span>",
                Cursor = Xwt.CursorType.Hand,
            };

            if (IdeTheme.UserInterfaceTheme == Theme.Light)
            {
                linkLabel.Markup = string.Format("<span color='#5C2D91'>{0}</span>", linkLabel.Markup);
            }

            linkLabel.ButtonReleased += (sender, e) => {
                var    binDir      = System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetEntryAssembly().Location);
                string licensePath = System.IO.Path.Combine(binDir, "branding", "License.txt");
                if (Platform.IsMac)
                {
                    var appDir = System.IO.Path.GetFullPath(System.IO.Path.Combine(binDir, "..", "..", "..", "..", ".."));
                    if (appDir.EndsWith(".app", StringComparison.Ordinal))
                    {
                        licensePath = System.IO.Path.Combine(appDir, "Contents", "License.txt");
                    }
                }
                if (!File.Exists(licensePath))
                {
                    MessageService.ShowError("License file is missing");
                }
                else
                {
                    DesktopService.OpenFile(licensePath);
                }
            };
            cbox.PackStart(linkLabel);
            infoBox.PackStart(cbox);

            linkLabel = new Xwt.Label {
                Markup     = string.Format("<span underline='true'>{0}</span>", GettextCatalog.GetString("Privacy Statement")),
                Cursor     = Xwt.CursorType.Hand,
                MarginLeft = 12
            };

            //TODO: factor out
            const string PRIVACY_URL = "https://go.microsoft.com/fwlink/?LinkID=824704";

            if (IdeTheme.UserInterfaceTheme == Theme.Light)
            {
                linkLabel.Markup = string.Format("<span color='#5C2D91'>{0}</span>", linkLabel.Markup);
            }
            linkLabel.ButtonReleased += (sender, e) => DesktopService.ShowUrl(PRIVACY_URL);
            infoBox.PackStart(linkLabel);

            infoBox.PackStart(new Xwt.Label()
            {
                Markup    = string.Format("<b>{0}</b>", GettextCatalog.GetString("Copyright")),
                MarginTop = 6,
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Text       = (DateTime.Now.Year == 2016 ? "© 2016" : "© 2016–" + DateTime.Now.Year) + " Microsoft Corp.",
                MarginLeft = 12
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = "© 2004–" + DateTime.Now.Year + " Xamarin Inc.",
                MarginLeft = 12
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = "© 2004–" + DateTime.Now.Year + " MonoDevelop contributors",
                MarginLeft = 12
            });

            this.ShowAll();
        }
		public AboutMonoDevelopTabPage ()
		{
			BorderWidth = 0;

			var aboutFile = BrandingService.GetFile ("AboutImage.png");
			if (aboutFile != null)
				imageSep = Xwt.Drawing.Image.FromFile (aboutFile);
			else
				imageSep = Xwt.Drawing.Image.FromResource ("AboutImage.png");

			PackStart (new ImageView (imageSep), false, false, 0);

			Xwt.VBox infoBox = new Xwt.VBox ();
			Xwt.FrameBox mbox = new Xwt.FrameBox (infoBox);

			infoBox.Spacing = 6;
			infoBox.Margin = 12;
			PackStart (mbox.ToGtkWidget (), false, false, 0);

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Version"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			infoBox.PackStart (new Xwt.Label () {
				Text = IdeVersionInfo.MonoDevelopVersion,
				MarginLeft = 12
			});

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("License"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Released under the GNU Lesser General Public License."),
				MarginLeft = 12
			});

			infoBox.PackStart (new Xwt.Label () {
				Text = GettextCatalog.GetString ("Copyright"),
				Font = infoBox.Font.WithWeight (Xwt.Drawing.FontWeight.Bold)
			});
			var cbox = new Xwt.HBox () {
				Spacing = 0,
				MarginLeft = 12
			};
			cbox.PackStart (new Xwt.Label ("© 2014 "));
			cbox.PackStart (new Xwt.LinkLabel () {
				Text = string.Format ("Joshua Granick"),
				Uri = new Uri ("http://www.joshuagranick.com")
			});
			infoBox.PackStart (cbox);
			infoBox.PackStart (new Xwt.Label () {
				Text = "© 2004-2013 MonoDevelop contributors",
				MarginLeft = 12
			});

			cbox = new Xwt.HBox () {
				Spacing = 0,
				MarginLeft = 12
			};
			cbox.PackStart (new Xwt.Label ("Some icons by "));
			cbox.PackStart (new Xwt.LinkLabel () {
				Text = string.Format ("Yusuke Kamiyamane"),
				Uri = new Uri ("http://p.yusukekamiyamane.com")
			});

			infoBox.PackStart (cbox);

			cbox = new Xwt.HBox () {
				Spacing = 0,
				MarginLeft = 12
			};
			cbox.PackStart (new Xwt.Label ("Some icons from the "));
			cbox.PackStart (new Xwt.LinkLabel () {
				Text = string.Format ("Silk icon set"),
				Uri = new Uri ("http://www.famfamfam.com/")
			});
			infoBox.PackStart (cbox);

			this.ShowAll ();
		}
Esempio n. 7
0
        public AboutMonoDevelopTabPage()
        {
            BorderWidth = 0;

            using (var stream = BrandingService.GetStream("AboutImage.png", true))
                imageSep = new Pixbuf(stream);
            PackStart(new Gtk.Image(imageSep), false, false, 0);

            Xwt.VBox     infoBox = new Xwt.VBox();
            Xwt.FrameBox mbox    = new Xwt.FrameBox(infoBox);

            infoBox.Spacing = 6;
            infoBox.Margin  = 12;
            PackStart(mbox.ToGtkWidget(), false, false, 0);

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("Version"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = IdeVersionInfo.MonoDevelopVersion,
                MarginLeft = 12
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("License"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = GettextCatalog.GetString("Released under the GNU Lesser General Public License."),
                MarginLeft = 12
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("Copyright"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            var cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };

            cbox.PackStart(new Xwt.Label("© 2011-2013 "));
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("Xamarin Inc."),
                Uri  = new Uri("http://www.xamarin.com")
            });
            infoBox.PackStart(cbox);
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = "© 2004-2013 MonoDevelop contributors",
                MarginLeft = 12
            });

            cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };
            cbox.PackStart(new Xwt.Label("Some icons by "));
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("Yusuke Kamiyamane"),
                Uri  = new Uri("http://p.yusukekamiyamane.com")
            });

            infoBox.PackStart(cbox);

            cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };
            cbox.PackStart(new Xwt.Label("Some icons from the "));
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("Silk icon set"),
                Uri  = new Uri("http://www.famfamfam.com/")
            });
            infoBox.PackStart(cbox);

            this.ShowAll();
        }
Esempio n. 8
0
        public AboutMonoDevelopTabPage()
        {
            BorderWidth = 0;

            var aboutFile = BrandingService.GetFile(AboutDialogImage.Name);

            if (aboutFile != null)
            {
                imageSep = Xwt.Drawing.Image.FromFile(aboutFile);
            }
            else
            {
                imageSep = Xwt.Drawing.Image.FromResource(AboutDialogImage.Name);
            }

            PackStart(new ImageView(imageSep), false, false, 0);

            Xwt.VBox     infoBox = new Xwt.VBox();
            Xwt.FrameBox mbox    = new Xwt.FrameBox(infoBox);

            infoBox.Spacing = 6;
            infoBox.Margin  = 12;
            PackStart(mbox.ToGtkWidget(), false, false, 0);

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("Version"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = IdeVersionInfo.MonoDevelopVersion,
                MarginLeft = 12
            });

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("License"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            var cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };

            cbox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("License is available at ")
            });
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("http://xamarin.com/xamarin-studio-license"),
                Uri  = new Uri("http://xamarin.com/xamarin-studio-license")
            });
            infoBox.PackStart(cbox);

            infoBox.PackStart(new Xwt.Label()
            {
                Text = GettextCatalog.GetString("Copyright"),
                Font = infoBox.Font.WithWeight(Xwt.Drawing.FontWeight.Bold)
            });
            cbox = new Xwt.HBox()
            {
                Spacing    = 0,
                MarginLeft = 12
            };
            cbox.PackStart(new Xwt.Label("© 2011-" + DateTime.Now.Year + " "));
            cbox.PackStart(new Xwt.LinkLabel()
            {
                Text = string.Format("Xamarin Inc."),
                Uri  = new Uri("http://www.xamarin.com")
            });
            infoBox.PackStart(cbox);
            infoBox.PackStart(new Xwt.Label()
            {
                Text       = "© 2004-" + DateTime.Now.Year + " MonoDevelop contributors",
                MarginLeft = 12
            });

            this.ShowAll();
        }