Browse Source

r7323@daniel-notebook (orig r3354): daniel | 2008-08-14 18:09:24 +0200

Fixed SD2-1265: Font size chosen in text editor options is not consistent with other Windows applications


git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/trunk@3356 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61
shortcuts
Daniel Grunwald 17 years ago
parent
commit
0b36168819
  1. 2
      src/Libraries/ICSharpCode.TextEditor/Project/Src/Document/HighlightingStrategy/FontContainer.cs

2
src/Libraries/ICSharpCode.TextEditor/Project/Src/Document/HighlightingStrategy/FontContainer.cs

@ -79,7 +79,7 @@ namespace ICSharpCode.TextEditor.Document @@ -79,7 +79,7 @@ namespace ICSharpCode.TextEditor.Document
}
set {
// 1440 twips is one inch
int pixelSize = (int)(value.SizeInPoints * 20 / TwipsPerPixelY);
int pixelSize = (int)Math.Round(value.SizeInPoints * 20 / TwipsPerPixelY);
defaultFont = value;
regularfont = new Font(value.FontFamily, pixelSize * TwipsPerPixelY / 20f, FontStyle.Regular);

Loading…
Cancel
Save