mirror of
https://github.com/RGBCube/serenity
synced 2025-05-30 17:48:12 +00:00
LibGUI: Remove more header dependencies from Widget.h
This commit is contained in:
parent
69400c2ca1
commit
e1ff4fa034
12 changed files with 26 additions and 8 deletions
|
@ -38,6 +38,7 @@
|
|||
#include <LibGUI/TextEditor.h>
|
||||
#include <LibGUI/Window.h>
|
||||
#include <LibGfx/Bitmap.h>
|
||||
#include <LibGfx/Font.h>
|
||||
#include <LibGfx/Palette.h>
|
||||
#include <ctype.h>
|
||||
#include <fcntl.h>
|
||||
|
@ -1500,4 +1501,14 @@ void TextEditor::set_syntax_highlighter(OwnPtr<SyntaxHighlighter> highlighter)
|
|||
}
|
||||
}
|
||||
|
||||
int TextEditor::line_height() const
|
||||
{
|
||||
return font().glyph_height() + m_line_spacing;
|
||||
}
|
||||
|
||||
int TextEditor::glyph_width() const
|
||||
{
|
||||
return font().glyph_width('x');
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue