Jump to content

User talk:Jean Abou Samra: Difference between revisions

Add topic
From LilyPond wiki
Latest comment: 21:10 by Jean Abou Samra in topic This wiki has no templates
 
(17 intermediate revisions by 3 users not shown)
Line 51: Line 51:


:Done. Thanks for providing the CSS code. [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 15:28, 6 December 2025 (UTC)
:Done. Thanks for providing the CSS code. [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 15:28, 6 December 2025 (UTC)
:: Ah, I missed that with this CSS code the quote characters are also in typewriter, which is not correct.  So please add <code>font-family: sans-serif;</code> to both the <code>samp:before</code> and <code>samp:after</code> block.
:: [I haven't found out how to display the quotes with the same font selected by the user to display the main font in Wiki – or is this fixed to always be sans-serif?]
::: Done. I don't know a better solution either. [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 14:30, 8 December 2025 (UTC)
:::Thanks! -- [[User:Lemzwerg|Lemzwerg]] ([[User talk:Lemzwerg|talk]]) 13:48, 9 December 2025 (UTC)
== Search issues ==
Jean,
To get nice snippet headings in the documentation, we often use non-letter stuff like opening and closing quotes in Wiki page titles.  However, as I've found out recently, this severely hampers searching.  For example, the snippet [[Using \arpeggioBracket to make divisi more visible]] cannot be immediately found by entering “Using arpeggioBracket” (i.e., without the backslash) into the search field.
I now wonder whether the Wiki can be configured to ignore quote characters and the like in the search.  If this is not possible, I have to add redirections for all articles with such characters in its name.  It's not a big deal since it can be done programmatically, however, not needing this would be a better solution. -- [[User:Lemzwerg|Lemzwerg]] ([[User talk:Lemzwerg|talk]]) 13:55, 9 December 2025 (UTC)
:AFAIU the autocompletion just matches by title prefix (to be clear, this is not about the search results page you get if you press Enter, which is much more complete). I think it's not too bad, not sure if there's any way to change it. [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 14:13, 9 December 2025 (UTC)
::OK, thanks.  What do you think of installing the [https://www.mediawiki.org/wiki/Extension:CirrusSearch Cirrus search extension]?  It seems that Wikimedia is using this by default, and it comes with fuzzy search support, AFAICS. -- [[User:Lemzwerg|Lemzwerg]] ([[User talk:Lemzwerg|talk]]) 14:47, 9 December 2025 (UTC)
:::It looks like there is no opensearch package in Fedora, and honestly I'm not too keen on setting up a tool as large and complex as MediaWiki itself requiring its own systemd services and networks ports and so on if it's only for the sake of this autocompletion… [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 18:20, 12 December 2025 (UTC)
== More fonts for the Wiki ==
Jean,
please have a look at the snippet [[Changing the default text font family]]: as can be seen, some font shapes for DejaVu Mono are missing.  Is it possible to get them added to the server that runs the Wiki?
BTW, the same holds for the [[UTF-8]] snippet, where Japanese is missing.
-- [[User:Lemzwerg|Lemzwerg]] ([[User talk:Lemzwerg|talk]]) 15:39, 12 December 2025 (UTC)
:Fixed. [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 18:34, 12 December 2025 (UTC)
::Thanks, but are you sure that the CJK font is working correctly?  I tried to modify the [[UTF-8]] snippet to trigger a re-rendering, but I still can't see any Japanese... -- [[User:Lemzwerg|Lemzwerg]] ([[User talk:Lemzwerg|talk]]) 20:44, 12 December 2025 (UTC)
:::Oops, indeed. But I don't understand why. On the server, <code>-dshow-available-fonts</code> does list "Noto Serif CJK JP". And curiously, if I remove all font settings and compile the code with different versions, it starts working between 2.25.12 and 2.25.13. [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 23:49, 12 December 2025 (UTC)
::::Ah, I forgot that Google added Font Variation (VF) versions of the CJK fonts, and the various GNU/Linux distros eagerly took them to make the font bundles much smaller.  Older LilyPond versions cannot reject these fonts correctly.
::::For me it works with 2.24.4 if you use the font <code>[https://github.com/notofonts/noto-cjk/blob/main/Serif/OTF/Japanese/NotoSerifCJKjp-Regular.otf NotoSerifCJKjp-Regular.otf]</code> (probably also installing the [https://github.com/notofonts/noto-cjk/blob/main/Serif/OTF/Japanese/NotoSerifCJKjp-Bold.otf bold version] for completeness), and this font is found first. -- [[User:Lemzwerg|Lemzwerg]] ([[User talk:Lemzwerg|talk]]) 04:24, 13 December 2025 (UTC)
:::::Thanks, I've added these fonts on the server as a workaround. The snippet now displays correctly. [[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 09:13, 13 December 2025 (UTC)
::::::Great, thanks! -- [[User:Lemzwerg|Lemzwerg]] ([[User talk:Lemzwerg|talk]]) 10:50, 13 December 2025 (UTC)
== This wiki has no templates ==
Would it be ok if I created some templates? And I am missing several AddOns, CharInsert would be nice for editing, SyntaxHighlight, Scribunto. I am running a rather private Lilypond Wiki in German for several years and have some experience with Wikis, [[User:Manuela|Manuela]] ([[User talk:Manuela|talk]]) 15:13, 18 December 2025 (UTC)
:Feel free to create all kinds of pages, including templates. However, I'd prefer if they were created as needed for specific pages (i.e., don't create templates "for the future" that aren't used on any pages). Also, I don't see much that could be factored between pages so what's your use case? In particular, please don't create templates similar [[wikipedia:Template:Em|<code><nowiki>{{em|...}}</nowiki></code> on Wikipedia]] that add friction to the editing process for a negligible payoff.
:I haven't installed the extensions you requested because:
:# I don't see any special characters that would be needed particularly often on this wiki specifically, and I'd rather not maintain a general list of special characters, this is the job of system-level input methods like Compose keys and character map apps IMHO.
:# It wouldn't make much sense to have syntax highlighting only for the few code snippets that use <code><nowiki><pre></nowiki></code>, as opposed to <code><nowiki><lilypond></nowiki></code>. However, if someone submits a change for adding syntax highlighting to the output of <code><nowiki><lilypond></nowiki></code> in the [https://gitlab.com/jeanas/LilyWiki extension] that defines this tag for the wiki, I'll be happy to review it.
:# Scribunto has security implications (e.g., the need to keep Lua updated), so I'd rather only install it if there is a compelling use case for that.
:[[User:Jean Abou Samra|Jean Abou Samra]] ([[User talk:Jean Abou Samra|talk]]) 21:10, 18 December 2025 (UTC)

Latest revision as of 21:10, 18 December 2025

Test of email notifications

[edit source]

This is a test. Jean Abou Samra Test Account (talk) 02:46, 2 November 2025 (UTC)Reply

Another test. Jean Abou Samra Test Account (talk) 03:04, 2 November 2025 (UTC)Reply
Third test. Jean Abou Samra Test Account (talk) 03:05, 2 November 2025 (UTC)Reply
Reply test. Jean Abou Samra (talk) 03:05, 2 November 2025 (UTC)Reply
Yet another test. Jean Abou Samra Test Account (talk) 03:14, 2 November 2025 (UTC)Reply

Default stylesheet for the Wiki

[edit source]

Jean,

you've recently removed paper indentation settings from Rest styles, arguing that no indentation is the default for this Wiki. However, this snippet is part of the “official” documentation that doesn't set the indentation to zero by default...

I thus wonder whether it makes sense to synchronize the Wiki with the LilyPond documentation by not providing a default value for the indentation. Another reason to stay with LilyPond's default is that a novice user who tries to compile a snippet might be surprised that it looks differently. -- Lemzwerg (talk) 16:51, 23 November 2025 (UTC)Reply

I'm surprised. This page of the contributor's guide implies indent = 0 is the default in doc snippets. Is it out of date? What are the exact settings used to compile snippets in the docs? It's been too long since I had any idea how the doc build works, I can't find this in the repo right now… Jean Abou Samra (talk) 17:13, 23 November 2025 (UTC)Reply
I took the style settings used on the wiki right from the usage manual in the section that says "you have to effectively mimick how lilypond-book runs lilypond"… Jean Abou Samra (talk) 17:15, 23 November 2025 (UTC)Reply
D'oh. You are correct. My mistake, my memory failed me, and of course I didn't check before writing :-)
Sorry for the noise -- Lemzwerg (talk) 17:22, 23 November 2025 (UTC)Reply

cropped SVG images

[edit source]

Jean, please have a look at the image in Custodes – the mensural custodes in the fourth staff are cropped. If you download the SVG image and use a program like `inkview` you can see that the image actually contains the complete glyphs, however, the bounding box is too tight (an old LilyPond issue, as you certainly know).

Is there a possibility to increase the bounding boxes of all images (both horizontally and vertically) using a post-processing step so that cropping can be avoided? -- Lemzwerg (talk) 10:40, 25 November 2025 (UTC)Reply

Seems a bit overkill to me. I've added a simple workaround to that snippet. Jean Abou Samra (talk) 12:41, 25 November 2025 (UTC)Reply
Nice, thanks! I didn't think of this simple fix. -- Lemzwerg (talk) 13:27, 25 November 2025 (UTC)Reply

Some CSS code for <samp>

[edit source]

Jean, what do you think of adding something like the following

body { quotes: '‘' '’'; }
samp:before { content: open-quote; } 
samp:after  { content: close-quote; }

to the Wiki CSS for the sake of better conversion to Texinfo? My reasoning is as follows.

There is a strong visual difference between <code> in the Wiki and @code in Texinfo output: the former produces typewriter text in a box, the latter uses just typewriter. This is fine with the fonts used for Texinfo output except for marking single letters: in Texinfo it is better to use @samp for this situation, producing typewriter text in quotes.

On the Wiki side I would thus like to use <samp>, which makelsr.pl converts to @samp. However, it currently produces plain typewriter in the Wiki, which isn't ideal since the contrast to plain text isn't large enough IMHO.

Example: The letter s is marked with <samp>. My suggestion: The letter ‘s’ is marked with <samp>.

An alternative would be to give <samp> the same appearance as <code>. -- Lemzwerg (talk) 17:15, 30 November 2025 (UTC)Reply

Done. Thanks for providing the CSS code. Jean Abou Samra (talk) 15:28, 6 December 2025 (UTC)Reply
Ah, I missed that with this CSS code the quote characters are also in typewriter, which is not correct. So please add font-family: sans-serif; to both the samp:before and samp:after block.
[I haven't found out how to display the quotes with the same font selected by the user to display the main font in Wiki – or is this fixed to always be sans-serif?]
Done. I don't know a better solution either. Jean Abou Samra (talk) 14:30, 8 December 2025 (UTC)Reply
Thanks! -- Lemzwerg (talk) 13:48, 9 December 2025 (UTC)Reply

Search issues

[edit source]

Jean,

To get nice snippet headings in the documentation, we often use non-letter stuff like opening and closing quotes in Wiki page titles. However, as I've found out recently, this severely hampers searching. For example, the snippet Using \arpeggioBracket to make divisi more visible cannot be immediately found by entering “Using arpeggioBracket” (i.e., without the backslash) into the search field.

I now wonder whether the Wiki can be configured to ignore quote characters and the like in the search. If this is not possible, I have to add redirections for all articles with such characters in its name. It's not a big deal since it can be done programmatically, however, not needing this would be a better solution. -- Lemzwerg (talk) 13:55, 9 December 2025 (UTC)Reply

AFAIU the autocompletion just matches by title prefix (to be clear, this is not about the search results page you get if you press Enter, which is much more complete). I think it's not too bad, not sure if there's any way to change it. Jean Abou Samra (talk) 14:13, 9 December 2025 (UTC)Reply
OK, thanks. What do you think of installing the Cirrus search extension? It seems that Wikimedia is using this by default, and it comes with fuzzy search support, AFAICS. -- Lemzwerg (talk) 14:47, 9 December 2025 (UTC)Reply
It looks like there is no opensearch package in Fedora, and honestly I'm not too keen on setting up a tool as large and complex as MediaWiki itself requiring its own systemd services and networks ports and so on if it's only for the sake of this autocompletion… Jean Abou Samra (talk) 18:20, 12 December 2025 (UTC)Reply

More fonts for the Wiki

[edit source]

Jean,

please have a look at the snippet Changing the default text font family: as can be seen, some font shapes for DejaVu Mono are missing. Is it possible to get them added to the server that runs the Wiki?

BTW, the same holds for the UTF-8 snippet, where Japanese is missing. -- Lemzwerg (talk) 15:39, 12 December 2025 (UTC)Reply

Fixed. Jean Abou Samra (talk) 18:34, 12 December 2025 (UTC)Reply
Thanks, but are you sure that the CJK font is working correctly? I tried to modify the UTF-8 snippet to trigger a re-rendering, but I still can't see any Japanese... -- Lemzwerg (talk) 20:44, 12 December 2025 (UTC)Reply
Oops, indeed. But I don't understand why. On the server, -dshow-available-fonts does list "Noto Serif CJK JP". And curiously, if I remove all font settings and compile the code with different versions, it starts working between 2.25.12 and 2.25.13. Jean Abou Samra (talk) 23:49, 12 December 2025 (UTC)Reply
Ah, I forgot that Google added Font Variation (VF) versions of the CJK fonts, and the various GNU/Linux distros eagerly took them to make the font bundles much smaller. Older LilyPond versions cannot reject these fonts correctly.
For me it works with 2.24.4 if you use the font NotoSerifCJKjp-Regular.otf (probably also installing the bold version for completeness), and this font is found first. -- Lemzwerg (talk) 04:24, 13 December 2025 (UTC)Reply
Thanks, I've added these fonts on the server as a workaround. The snippet now displays correctly. Jean Abou Samra (talk) 09:13, 13 December 2025 (UTC)Reply
Great, thanks! -- Lemzwerg (talk) 10:50, 13 December 2025 (UTC)Reply

This wiki has no templates

[edit source]

Would it be ok if I created some templates? And I am missing several AddOns, CharInsert would be nice for editing, SyntaxHighlight, Scribunto. I am running a rather private Lilypond Wiki in German for several years and have some experience with Wikis, Manuela (talk) 15:13, 18 December 2025 (UTC)Reply

Feel free to create all kinds of pages, including templates. However, I'd prefer if they were created as needed for specific pages (i.e., don't create templates "for the future" that aren't used on any pages). Also, I don't see much that could be factored between pages so what's your use case? In particular, please don't create templates similar {{em|...}} on Wikipedia that add friction to the editing process for a negligible payoff.
I haven't installed the extensions you requested because:
  1. I don't see any special characters that would be needed particularly often on this wiki specifically, and I'd rather not maintain a general list of special characters, this is the job of system-level input methods like Compose keys and character map apps IMHO.
  2. It wouldn't make much sense to have syntax highlighting only for the few code snippets that use <pre>, as opposed to <lilypond>. However, if someone submits a change for adding syntax highlighting to the output of <lilypond> in the extension that defines this tag for the wiki, I'll be happy to review it.
  3. Scribunto has security implications (e.g., the need to keep Lua updated), so I'd rather only install it if there is a compelling use case for that.
Jean Abou Samra (talk) 21:10, 18 December 2025 (UTC)Reply