Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2019-05-13 08:36:21

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

notextile

The <notextile /> tag does not work when there is no space before or after it. Is this expected behaviour?

Sample code

p. something here<notextile><txp::note no="1" txt="footnote here." pos="top" /></notextile>

this works

p. something here <notextile><txp::note no="1" txt="footnote here." pos="top" /></notextile>

The reason I would like the first to work is because it prevents the footnote number from moving to a new line.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#2 2019-05-13 10:06:16

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,726
Website

Re: notextile

Hmm, I thought you should be able to do that by putting square brackets around it, e.g.

something here[^2^].

produces something here2.

But neither:

something here[<notextile> … </notextile>]

nor

something here[== … ==]

seem to work :-/


TXP Builders – finely-crafted code, design and txp

Offline

#3 2019-05-13 13:44:19

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: notextile

Hmmm. Although it includes the actual square brackets, after parsing, it does work. Is there a way not to have the square brackets shown?


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#4 2019-05-13 14:51:56

etc
Developer
Registered: 2010-11-11
Posts: 5,189
Website GitHub

Re: notextile

Hi guys,

Looking at the code, <notextile> or == must be preceded by a space, >, [, ( or { to be detected. In all cases, the preceding character is preserved. It can eventually be converted on further processing, but not in your “footnote” case. If you need to make it invisible, try

something here<!---->== … ==

Arguably, in the case of <notextile> this might be considered as a bug, though I’m not sure what you are trying to achieve here.

Online

#5 2019-05-13 15:05:54

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: notextile

etc wrote #317977:

Hi guys,

Arguably, in the case of <notextile> this might be considered as a bug, though I’m not sure what you are trying to achieve here.

It is more of an aesthetic problem rather than a functional one. I am trying to avoid the rare occurrences where the footnotes are pushed to the next line.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#6 2019-05-13 23:05:13

phiw13
Plugin Author
From: Japan
Registered: 2004-02-27
Posts: 3,189
Website

Re: notextile

colak wrote #317978:

It is more of an aesthetic problem rather than a functional one. I am trying to avoid the rare occurrences where the footnotes are pushed to the next line.

A non-breaking (&160;) space before the footnote node? (that would work unless the footnote node is set to display:inline-block or some such).


Where is that emoji for a solar powered submarine when you need it ?
Sand space – admin theme for Textpattern

Offline

#7 2019-05-14 05:00:48

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: notextile

phiw13 wrote #317982:

A non-breaking (&160;) space before the footnote node? (that would work unless the footnote node is set to display:inline-block or some such).

Hi Philippe,

No, that would not work because the notextile tags would not be recognised. :(


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#8 2019-06-08 09:02:57

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: notextile

etc wrote #317977:

Arguably, in the case of <notextile> this might be considered as a bug, though I’m not sure what you are trying to achieve here.

The bracket code is only supported for links.

It also works for spans, soft of, but due to buggy non-functional conditional:

if (($m['pre'] && !$m['tail']) || ($m['tail'] && !$m['pre'])) {
      $out = $m['pre'].$out.$m['tail'];
}

Which results other strange stuff it is not supposed be doing. It’s a feature due to a bug, so to speak.

Last edited by Gocom (2019-06-08 09:03:06)

Offline

#9 2019-06-08 11:15:32

Gocom
Developer Emeritus
From: Helsinki, Finland
Registered: 2006-07-14
Posts: 4,533
Website

Re: notextile

Now the square bracket wrapping can be used for span tags and the special inline escaping syntaxes such as ==; now an actually intended feature extending the bracket syntax from links to other span tags, and not a result of a bug.

See span-wrappers fixture for syntax examples and what you should expect and what not.

Last edited by Gocom (2019-06-08 11:16:11)

Offline

#10 2019-06-08 16:42:37

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: notextile

Gocom wrote #318410:

Now the square bracket wrapping can be used for span tags and the special inline escaping syntaxes such as ==; now an actually intended feature extending the bracket syntax from links to other span tags, and not a result of a bug.

See span-wrappers fixture for syntax examples and what you should expect and what not.

yummy!!!!


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#11 2020-01-24 19:55:37

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: notextile

Just checking in to say that the additions to textile have solved this issue. But it wouldn’t be me if I did not push it to some insane level. The only way I found to show this snippet as a code in my install

[==<txp::note no="1" txt="txt" pos="top" />==]

was to change most of the non alpha characters to their entities and let textile do its thing:)

&#91;&#61;&#61;&#60;txp::note no&#61;&#34;1&#34; txt&#61;&#34;txt&#34; pos&#61;&#34;top&#34; /&#62;&#61;&#61;&#93;

I think that the changes are really great!


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

Board footer

Powered by FluxBB