From a057e13fb4331b17442028a0c7ed90a53241f0a2 Mon Sep 17 00:00:00 2001 From: Albrecht Schlosser Date: Mon, 29 Dec 2025 20:02:06 +0100 Subject: Improve code snapshot generation for PDF docs (#1353) CMake: execute `code_snapshot` separately for each file we want to scan so we can create timestamps and generate PNG images only if the source file (e.g. unicode.dox) was modified. documentation/src/unicode.dox: remove output folder `generated`, use only the filename. CMake sets the current working directory as needed. util/code_snapshot.cxx: format and improve comments, reset code buffer so we can generate multiple images per input file. --- documentation/src/unicode.dox | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'documentation/src/unicode.dox') diff --git a/documentation/src/unicode.dox b/documentation/src/unicode.dox index b640e170e..c11308ca3 100644 --- a/documentation/src/unicode.dox +++ b/documentation/src/unicode.dox @@ -22,7 +22,7 @@ are not yet implemented. International code test for HTML and PDF: -\code_international{"generated/unicode_about.png"} +\code_international{"unicode_about.png"} // This is a test // 日本語テストテキスト // 中文测试文本 @@ -70,11 +70,11 @@ doesn't break legacy ASCII code. Functions to check and analyze UTF-8 text: fl_utf8test() - Check if a string contains valid UTF-8 -\code +\code_international{"unicode_hello.png"} const char* text = "Hello 世界"; int result = fl_utf8test(text, strlen(text)); // Returns: 0=invalid, 1=ASCII, 2=2-byte chars, 3=3-byte chars, 4=4-byte chars -\endcode +\endcode_international fl_utf8len() - Get the length in bytes of a UTF-8 octet \code -- cgit v1.2.3