From 68f6d75ee3f2aa4bf20ac3df706303e586cff323 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Wed, 18 Oct 2023 11:29:58 +0200 Subject: [PATCH] Doc++ --- doc/changelog.dox | 2 +- src/Magnum/Text/AbstractFont.h | 10 +++++----- src/Magnum/Text/DistanceFieldGlyphCache.h | 4 ++++ src/Magnum/Text/GlyphCache.h | 8 +++----- src/MagnumPlugins/MagnumFont/MagnumFont.h | 3 ++- 5 files changed, 15 insertions(+), 12 deletions(-) diff --git a/doc/changelog.dox b/doc/changelog.dox index b8fecf55d..cedd92d11 100644 --- a/doc/changelog.dox +++ b/doc/changelog.dox @@ -383,7 +383,7 @@ See also: @ref GL::Framebuffer instead of a @ref GL::Texture as an output for an easier ability to download the resulting image on OpenGL ES platforms; the @ref magnum-distancefieldconverter "magnum-distancefieldconverter" - utility thus now compiles works and on OpenGL ES 3+ as well + utility thus now compiles and works on OpenGL ES 3+ as well @subsubsection changelog-latest-new-trade Trade library diff --git a/src/Magnum/Text/AbstractFont.h b/src/Magnum/Text/AbstractFont.h index 99ca08b34..1dd179da3 100644 --- a/src/Magnum/Text/AbstractFont.h +++ b/src/Magnum/Text/AbstractFont.h @@ -26,7 +26,7 @@ */ /** @file - * @brief Class @ref Magnum::Text::AbstractFont, @ref Magnum::Text::AbstractLayouter, enum @ref Magnum::Text::FontFeature, enum set @ref Magnum::Text::FontFeatures + * @brief Class @ref Magnum::Text::AbstractFont, enum @ref Magnum::Text::FontFeature, enum set @ref Magnum::Text::FontFeatures */ #include @@ -176,9 +176,9 @@ code reuse. @section Text-AbstractFont-data-dependency Data dependency -The @ref AbstractLayouter instances returned from @ref layout() have a code and -data dependency on the dynamic plugin module --- since their implementation is -in the plugin module itself, the plugin can't be unloaded until the returned +The @ref AbstractShaper instances returned from @ref createShaper() have a code +and data dependency on the dynamic plugin module --- since their implementation +is in the plugin module itself, the plugin can't be unloaded until the returned instance is destroyed. @section Text-AbstractFont-subclassing Subclassing @@ -186,7 +186,7 @@ instance is destroyed. The plugin needs to implement the @ref doFeatures(), @ref doClose(), @ref doCreateShaper() functions, either @ref doCreateGlyphCache() or @ref doFillGlyphCache() and one or more of `doOpen*()` functions. See also -@ref AbstractLayouter for more information. +@ref AbstractShaper for more information. In order to support @ref FontFeature::FileCallback, the font needs to properly use the callbacks to both load the top-level file in @ref doOpenFile() and also diff --git a/src/Magnum/Text/DistanceFieldGlyphCache.h b/src/Magnum/Text/DistanceFieldGlyphCache.h index 5ca97c59c..9c39291ad 100644 --- a/src/Magnum/Text/DistanceFieldGlyphCache.h +++ b/src/Magnum/Text/DistanceFieldGlyphCache.h @@ -68,6 +68,10 @@ channels. @snippet MagnumText-gl.cpp DistanceFieldGlyphCache-usage +See the @ref Renderer class for information about text rendering. The +@ref AbstractGlyphCache base class has more information about general glyph +cache usage. + @note This class is available only if Magnum is compiled with @ref MAGNUM_TARGET_GL enabled (done by default). See @ref building-features for more information. diff --git a/src/Magnum/Text/GlyphCache.h b/src/Magnum/Text/GlyphCache.h index 7171f4084..9b0f8cf8f 100644 --- a/src/Magnum/Text/GlyphCache.h +++ b/src/Magnum/Text/GlyphCache.h @@ -49,11 +49,9 @@ Create the @ref GlyphCache object with sufficient size and then call @snippet MagnumText-gl.cpp GlyphCache-usage -See the @ref Renderer class for information about text rendering. - -This class supports @ref GlyphCacheFeature::ImageDownload (and thus calling -@ref image()) only on desktop OpenGL, due to using @ref GL::Texture::image(), -which is not available on @ref MAGNUM_TARGET_GLES "OpenGL ES" platforms. +See the @ref Renderer class for information about text rendering. The +@ref AbstractGlyphCache base class has more information about general glyph +cache usage. @todo Some way for Font to negotiate or check internal texture format @todo Default glyph 0 with rect 0 0 0 0 will result in negative dimensions when diff --git a/src/MagnumPlugins/MagnumFont/MagnumFont.h b/src/MagnumPlugins/MagnumFont/MagnumFont.h index 8371c89b0..4725a7015 100644 --- a/src/MagnumPlugins/MagnumFont/MagnumFont.h +++ b/src/MagnumPlugins/MagnumFont/MagnumFont.h @@ -157,7 +157,8 @@ need to instantiate a manager for them and register it with @snippet plugins.cpp MagnumFont-importer-register -See @ref building, @ref cmake and @ref plugins for more information. +See @ref building, @ref cmake, @ref plugins and @ref file-formats for more +information. */ class MAGNUM_MAGNUMFONT_EXPORT MagnumFont: public AbstractFont { public: