RNS Logo

rns.recipes

◈ 9ce92808be498e9e05590ff27cbfdfe4
RNS 1.5.5 released https://pypi.org/project/rns/

Image tag w=int setting sets width to what exactly - and a bigger question

Started by NONGKHAEM_BKK_TH e23e9a470d42f05d... ·

NONGKHAEM_BKK_TH e23e9a470d42f05d...
edited #1

In micron image tags, I know w=n means width=native.
But what is w=50?
is that 50px, or 50%?
And 50% of what? Of the available page width, or 50% of the image width?

 

And is this documented somewhere, or considered to be 'experimental' from source?
I searched for the FM so I could RTFM but failed. And i searched a lot.

 

The reason I ask is two fold. First, because I'm hosting a small gallery at a3ab2d22647bf8a67937d229d3cbc506:/page/gallery.mu which I wanted to share, but now I don't know if my images will render correctly depending on the client used. This is annoying, because I don't want nomadnet to become the kind of place where we test for user agents. That's the legacy web type problem.

 

Second, because I just raised a bug with MeshchatX rendering 50 as '50 pixel wide' instead of 50%. And then, when I used 50%, it would render at 50% of the image width, but nomadnet over kitty seems to render at 50% of the available page with, and setting it to 100 fills my screen. This make no sense.

 

You can see where this is going: given there is no manual to refer to, I genuinely cannot decide which client is rendering 'correctly'. Part of me thinks it must be nomadnet , because nomadnet is canon.

 

But then, if nomadnet is correct, why is it rendering 50 as '50% of page width', which on my mac just happens to the be same size as opening the files in preview (sounds incorrect to me) . When i set w to n, expecting 480 pixel to look like 480 pixels, yet the image appears exactly twice as big as the files as seen in preview.

 

In other words, it's genuinely impossible, unless i was to go into the nomadnet codebase and look at the renderer, to know who is right.

Sorry for the wall of text but I have ADHD-H and I won't sleep until I figure this out lol

Mark 8dd57a7382268096...
#2

Lol, the FM is indeed not so easy to search for, since it's included in NomadNet itself :) Check the "Guide -> Markdown" section. Basically, everything is documented in the "Guide" section of nomadnet, so you always have the manual with you :)

 

  • w=50% is 50% of the available width, whatever that is at the moment (could be smaller than full page width due to section indents, for example)
  • w=22 is 22 terminal columns.
  • w=n will attempt to match the image's size as closely as possible to it's native pixel size, given the terminal colum/row pixel width/height, but never exceed 100% of the available width.
Mark 8dd57a7382268096...
#3

"Guide -> Micron Markup", it should have said. I've just been working on some markdown conversion stuff, and apparently the word got stuck ;)

 

Hope that helps you sleep :)

NONGKHAEM_BKK_TH e23e9a470d42f05d...
#4

Mark wrote:

"Guide -> Micron Markup", it should have said. I've just been working on some markdown conversion stuff, and apparently the word got stuck ;)

Hope that helps you sleep :)

 

Thank you so much - I went to sleep and slept very well! :)

Post a Reply

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

Log in to upload images

Quote
Copied to clipboard