mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-22 12:00:45 +00:00
* Headers/Additions/GNUstepGUI/GSLayoutManager.h,
* Source/GSLayoutManager.m: Add new methods -defaultLineHeightForFont: and -defaultBaselineOffsetForFont:.
This commit is contained in:
parent
30d0dc66ee
commit
e4ecfb0801
3 changed files with 23 additions and 0 deletions
|
@ -1,3 +1,9 @@
|
|||
2022-11-05 Fred Kiefer <FredKiefer@gmx.de>
|
||||
|
||||
* Headers/Additions/GNUstepGUI/GSLayoutManager.h,
|
||||
* Source/GSLayoutManager.m: Add new methods
|
||||
-defaultLineHeightForFont: and -defaultBaselineOffsetForFont:.
|
||||
|
||||
2022-10-11 Riccardo Mottola <rm@gnu.org>
|
||||
|
||||
* Source/NSTextView.m
|
||||
|
|
|
@ -139,6 +139,13 @@ how it's supposed to work. It's functional and correct, but it isn't fast. */
|
|||
- (BOOL) showsControlCharacters;
|
||||
|
||||
|
||||
#if OS_API_VERSION(MAC_OS_X_VERSION_10_2, GS_API_LATEST)
|
||||
- (CGFloat) defaultLineHeightForFont: (NSFont*)theFont;
|
||||
#endif
|
||||
#if OS_API_VERSION(MAC_OS_X_VERSION_10_5, GS_API_LATEST)
|
||||
- (CGFloat) defaultBaselineOffsetForFont: (NSFont*)theFont;
|
||||
#endif
|
||||
|
||||
/** Font handling **/
|
||||
|
||||
- (BOOL) usesScreenFonts;
|
||||
|
|
|
@ -3089,6 +3089,16 @@ See [NSTextView -setTextContainer:] for more information about these calls.
|
|||
return showsControlCharacters;
|
||||
}
|
||||
|
||||
- (CGFloat) defaultLineHeightForFont: (NSFont*)theFont
|
||||
{
|
||||
return [theFont defaultLineHeightForFont];
|
||||
}
|
||||
|
||||
- (CGFloat) defaultBaselineOffsetForFont: (NSFont*)theFont
|
||||
{
|
||||
return 0.0;
|
||||
}
|
||||
|
||||
/*
|
||||
Note that NSLayoutManager completely overrides this (to perform more
|
||||
intelligent invalidation of layout using the constraints on layout it
|
||||
|
|
Loading…
Reference in a new issue