This class is used to generate bold, italic and bold/italic fonts out of a base font.
		public DefaultTextEditorProperties()
		{
			if (DefaultFont == null) {
				DefaultFont = new Font("Courier New", 10);
			}
			this.fontContainer = new FontContainer(DefaultFont);
		}
Exemple #2
0
		public DefaultTextEditorProperties()
		{
			if (DefaultFont == null) {
				DefaultFont = new Font("Courier New", 10);
			}
			this.fontContainer = new FontContainer(DefaultFont);
		}
		/// <value>
		/// The font used
		/// </value>
		public Font GetFont(FontContainer fontContainer)
		{
			if (Bold) {
				return Italic ? fontContainer.BoldItalicFont : fontContainer.BoldFont;
			}
			return Italic ? fontContainer.ItalicFont : fontContainer.RegularFont;
		}
Exemple #4
0
 /// <value>
 /// The font used
 /// </value>
 public Font GetFont(FontContainer fontContainer)
 {
     if (Bold)
     {
         return(Italic ? fontContainer.BoldItalicFont : fontContainer.BoldFont);
     }
     return(Italic ? fontContainer.ItalicFont : fontContainer.RegularFont);
 }
 public DefaultTextEditorProperties()
 {
     if (DefaultFont == null)
     {
         DefaultFont = new Font("Consolas", 9.75F);
     }
     this.fontContainer = new FontContainer(DefaultFont);
 }
 public Font GetFont(FontContainer fontContainer)
 {
     if (this.Bold)
     {
         if (!this.Italic)
         {
             return(fontContainer.BoldFont);
         }
         return(fontContainer.BoldItalicFont);
     }
     if (!this.Italic)
     {
         return(fontContainer.RegularFont);
     }
     return(fontContainer.ItalicFont);
 }
Exemple #7
0
 /// <value>
 /// The font used
 /// </value>
 public Font GetFont(FontContainer fontContainer)
 {
     if (Bold)
     {
         return(Italic ? fontContainer.BoldItalicFont : fontContainer.BoldFont);
     }
     if (Underline)
     {
         return(fontContainer.UnderlineFont);
     }
     if (Strikeout)
     {
         return(fontContainer.StrikeoutFont);
     }
     return(Italic ? fontContainer.ItalicFont : fontContainer.RegularFont);
 }
        public DefaultTextEditorProperties()
        {
            //DefaultFont = new Font("Consolas", 10);
            FontContainer = new FontContainer(DefaultFont);
            Font = DefaultFont;

            TabIndent = 4;
            IndentationSize = 4;
            IndentStyle = IndentStyle.Smart;
            DocumentSelectionMode = DocumentSelectionMode.Normal;
            Encoding = System.Text.Encoding.UTF8;
            BracketMatchingStyle  = BracketMatchingStyle.After;

            ShowMatchingBracket = true;
            ShowLineNumbers = true;
            EnableFolding = true;
            ShowVerticalRuler = true;
            TextRenderingHint = TextRenderingHint.SystemDefault;
            MouseWheelScrollDown = true;
            MouseWheelTextZoom = true;

            VerticalRulerRow = 80;
            LineViewerStyle = LineViewerStyle.None;
            LineTerminator = "\r\n";
            AutoInsertCurlyBracket = true;

            DefaultColor = new HighlightBackground("WindowText", "Window", false, false);
            SelectionColor = new HighlightColor("HighlightText", "Highlight", false, false);
            VRulerColor = new HighlightColor("ControlLight", "Window", false, false);
            InvalidLinesColor = new HighlightColor(Color.Red, false, false);
            CaretMarkerColor = new HighlightColor(Color.Yellow, false, false);
            CaretLineColor = new HighlightBackground("ControlLight", "Window", false, false);
            LineNumbersColor = new HighlightBackground("ControlDark", "Window", false, false);
            FoldLineColor = new HighlightColor("ControlDark", false, false);
            FoldMarkerColor = new HighlightColor("WindowText", "Window", false, false);
            SelectedFoldLineColor = new HighlightColor("WindowText", false, false);
            EOLMarkersColor = new HighlightColor("ControlLight", "Window", false, false);
            SpaceMarkersColor = new HighlightColor("ControlLight", "Window", false, false);
            TabMarkersColor = new HighlightColor("ControlLight", "Window", false, false);
        }
        public DefaultTextEditorProperties()
        {
            //DefaultFont = new Font("Consolas", 10);
            FontContainer = new FontContainer(DefaultFont);
            Font          = DefaultFont;

            TabIndent             = 4;
            IndentationSize       = 4;
            IndentStyle           = IndentStyle.Smart;
            DocumentSelectionMode = DocumentSelectionMode.Normal;
            Encoding             = System.Text.Encoding.UTF8;
            BracketMatchingStyle = BracketMatchingStyle.After;

            ShowMatchingBracket  = true;
            ShowLineNumbers      = true;
            EnableFolding        = true;
            ShowVerticalRuler    = true;
            TextRenderingHint    = TextRenderingHint.SystemDefault;
            MouseWheelScrollDown = true;
            MouseWheelTextZoom   = true;

            VerticalRulerRow       = 80;
            LineViewerStyle        = LineViewerStyle.None;
            LineTerminator         = "\r\n";
            AutoInsertCurlyBracket = true;

            DefaultColor          = new HighlightBackground("WindowText", "Window", false, false);
            SelectionColor        = new HighlightColor("HighlightText", "Highlight", false, false);
            VRulerColor           = new HighlightColor("ControlLight", "Window", false, false);
            InvalidLinesColor     = new HighlightColor(Color.Red, false, false);
            CaretMarkerColor      = new HighlightColor(Color.Yellow, false, false);
            CaretLineColor        = new HighlightBackground("ControlLight", "Window", false, false);
            LineNumbersColor      = new HighlightBackground("ControlDark", "Window", false, false);
            FoldLineColor         = new HighlightColor("ControlDark", false, false);
            FoldMarkerColor       = new HighlightColor("WindowText", "Window", false, false);
            SelectedFoldLineColor = new HighlightColor("WindowText", false, false);
            EOLMarkersColor       = new HighlightColor("ControlLight", "Window", false, false);
            SpaceMarkersColor     = new HighlightColor("ControlLight", "Window", false, false);
            TabMarkersColor       = new HighlightColor("ControlLight", "Window", false, false);
        }
Exemple #10
0
 public override Font GetFont(FontContainer fontContainer)
 {
     return(null);
 }
Exemple #11
0
 public virtual Font GetFont(FontContainer fontContainer)
 {
     return(color.GetFont(fontContainer));
 }
			public override Font GetFont(FontContainer fontContainer)
			{
				return null;
			}
		public virtual Font GetFont(FontContainer fontContainer)
		{
			return color.GetFont(fontContainer);
		}
		private SharpDevelopTextEditorProperties()
		{
			properties = PropertyService.Get("ICSharpCode.TextEditor.Document.Document.DefaultDocumentAggregatorProperties", new Properties());
			fontContainer = new FontContainer(FontContainer.ParseFont(properties.Get("DefaultFont", WinFormsResourceService.DefaultMonospacedFont.ToString())));
			properties.PropertyChanged += new PropertyChangedEventHandler(CheckFontChange);
		}