RNS Logo

rns.recipes

◈ 9ce92808be498e9e05590ff27cbfdfe4
Upcoming RNS 1.6.0 https://rns.recipes/forum/general/upcoming-rns-160-help-testing

literals `=

Started by tabletop 2cf71240ef8179b7... ·

tabletop 03757f51216a5937...
edited #1

In nomadnet (micron) I am trying to display = in a post I wrote about how to display a text file including the comment lines beginning with '#'. I tried to use 3 lines of = however when I do this it renders nothing. Any advise would be much appreciated.

Rudi Mentaire 65e0ce50386e9c4e...
edited #2

"In a post" means you are not talking about rendering a micron page but about rendering a post in a forum or hub? I don't know what rules apply there (and guess they differ from case to case) but text you post in this forum for example is not strictly interpreted as pure micron.

 

Lots of examples of backtick+equals-sign uses can be found in the nomadnet Guide, but I guess consulting these will not answer your question.

tabletop 03757f51216a5937...
#3

Thanks for responding Rudi. I used the wrong terminology (post). This is a micron page near the bottom of: f5edf692bee2c9388557bdaf366400a4:/page/blog/20261103.mu

Rudi Mentaire 65e0ce50386e9c4e...
#4

Ok, I see. Side note: I never wrote a single line of micron. You probably have more knowlegde than me.

 

I had a look at the micron parser implementation though (nomadnet/ui/textui/MicronParser.py) and also at the implementation of the Guide tab in the nomadnet application, and what you want should just work out of the box I think.

 

Background: AFAIU, the nomadnet micron parser searches linewise for a line beginning with backquote+equals-sign. For every line found, it toggles a "literal" named state. When this state is active, lines are, yeah, really just copied literally, including hashes. Right?

 

And in nomadnet/ui/textui/Guide.py I think there is an example showing that this works. Because there is an example of line hiding using hashes included. And the second half of the generated page consists of the literal micron source appended for reference. The (source) line starting with a hash is visible in the viewer. And AFAIU everything gets treated by the micron parser.

 

So unless there is a misunderstanding in my reading, either your micron source contains an error, or you have found a bug in at least the micron parser you tried (does the problem occur in all applications btw?).

 

Maybe others can tell more. If not, a minimal reproducing example maybe would be helpful.

Post a Reply

Supports Markdown: **bold**, *italic*, `code`, ```code blocks```, [links](url)

Log in to upload images

Quote
Copied to clipboard