Attributes substitution on formatted text

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Attributes substitution on formatted text

Daiane
I've been using the user defined variables a lot along my text, but suddenly I realized I cannot format a substitution.

For example, I have a variable (or attribute)

:tfile: target-file-used.txt


And I want to make the result of the substitution formatted in monospaced (or bold)

so I have tried:

Then copy the result in the file `~/user/{tfile}` to make something.

But I got the literal {tfile}  as the output, it's monospaced, but I want the content of variable instead.

I assume it's because substitution is disabled by default, like in http://mrhaki.blogspot.com/2014/05/awesome-asciidoc-substitute-attribute.html (and many other references like that) but I found no way to [subs="attributes"] in a in-line formatting.

How could I do that?

Thanks in advance for any hint.
Reply | Threaded
Open this post in threaded view
|

Re: Attributes substitution on formatted text

Andrew Carver
Reply | Threaded
Open this post in threaded view
|

Re: Attributes substitution on formatted text

Daiane
Thanks a lot Andrew!

I had tried the "pass" stuff. I must admit I don't understand what that means at all.  Anyway, you pointing me that link make me create a separate file to test it again (to paste the test here) and I realized the problem was not on the formatting, but on my variable.

In the example I copied here it was simple lines, but on my project it is a set of files including each other and one of them is the file with all the variables. The one variable I want to format was wrong. Thanks a lot again!

Only for future reference:

When I test

= Title of mine

:tfile: target-file-used.txt


Then copy the result in the file `~/user/{tfile}` to make something.

Then copy the result in the file pass[`~/user/{tfile}`] to make something.

Then copy the result in the file pass:q[`~/user/{tfile}`] to make something.

The end.


I get (italic here is monospaced in html or pdf output file)


Title of mine

Then copy the result in the file ~/user/target-file-used.txt to make something.

Then copy the result in the file pass[~/user/target-file-used.txt] to make something.

Then copy the result in the file ~/user/{tfile} to make something.

The end
.

Thanks again, and I apologize for my mistake