commit e80e55df2fd4b9df69ef42bd74cb9b7ff87e79f4
Author: Koji Yokota <[email protected]>
Date: Sat Nov 8 12:09:24 2025 +0900
Add some comments on function usage
---
src/MetricsInfo.h | 3 ++-
src/frontends/NullPainter.h | 4 ++--
src/frontends/Painter.h | 2 ++
src/frontends/qt/GuiPainter.h | 4 ++++
4 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/src/MetricsInfo.h b/src/MetricsInfo.h
index 5efa72a8ca..8804f09b23 100644
--- a/src/MetricsInfo.h
+++ b/src/MetricsInfo.h
@@ -126,7 +126,8 @@ public:
void draw(int x, int y, char_type c);
///
void draw(int x, int y, docstring const & str);
- ///
+ /// Draw preedit char using char_format_index for format
+ /// f is used to get the font size in the text mode of mathed
void draw(int x, int y, char_type c, frontend::InputMethod const * im,
pos_type const char_format_index, FontInfo const * f =
nullptr);
diff --git a/src/frontends/NullPainter.h b/src/frontends/NullPainter.h
index 208c83417a..05716322ee 100644
--- a/src/frontends/NullPainter.h
+++ b/src/frontends/NullPainter.h
@@ -77,11 +77,11 @@ public:
void text(int, int, docstring const &, Font const &,
Color, size_type, size_type, double, double) override {}
- /// draw a char with input method
+ /// draw a char with input method, FontInfo is used in mathed
void text(int, int, char_type, InputMethod const *, pos_type const,
FontInfo const * = nullptr, Direction const = Auto) override
{}
- /// draw a string with input method
+ /// draw a string with input method, FontInfo is used in mathed
void text(int, int, docstring const &, InputMethod const *, pos_type
const,
FontInfo const * = nullptr,Direction const = Auto) override {}
diff --git a/src/frontends/Painter.h b/src/frontends/Painter.h
index 5c32b5da1d..f6054068cf 100644
--- a/src/frontends/Painter.h
+++ b/src/frontends/Painter.h
@@ -161,10 +161,12 @@ public:
double wordspacing, double textwidth) = 0;
/// draw a char at position x, y (y is the baseline) using input method
+ /// f is used to get the font size in the text mode of mathed
virtual void text(int, int, char_type, InputMethod const *, pos_type
const,
FontInfo const * = nullptr, Direction const = Auto) =
0;
/// draw a string at position x, y (y is the baseline) using input
method.
+ /// f is used to get the font size in the text mode of mathed
virtual void text(int x, int y, docstring const & str,
InputMethod const * im, pos_type const
char_format_index,
FontInfo const * f = nullptr, Direction const dir =
Auto) = 0;
diff --git a/src/frontends/qt/GuiPainter.h b/src/frontends/qt/GuiPainter.h
index ff7c53fe10..9988e43569 100644
--- a/src/frontends/qt/GuiPainter.h
+++ b/src/frontends/qt/GuiPainter.h
@@ -137,10 +137,14 @@ public:
double wordspacing, double textwidth) override;
/// draw a char at position x, y (y is the baseline) using input method
+ /// char_format_index specifies preedit format
+ /// f is used to get the font size in the text mode of mathed
void text(int x, int y, char_type c, InputMethod const * im,
pos_type const char_format_index, FontInfo const * f =
nullptr,
Direction const dir = Auto) override;
/// draw a string at position x, y (y is the baseline) using input
method.
+ /// char_format_index specifies preedit format
+ /// f is used to get the font size in the text mode of mathed
void text(int x, int y, docstring const & str, InputMethod const * im,
pos_type const char_format_index, FontInfo const * f =
nullptr,
Direction const dir = Auto) override;
--
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs