loopspace / tikzmark

The dread tikzmark arrives on github
14 stars 3 forks source link

Modify `verbatim` to copy and paste from documentation #10

Closed pablgonz closed 5 years ago

pablgonz commented 5 years ago

The documentation can be modified so that when copying the examples they keep the correct spacing and characters such as --? For example, by copying and pasting using evince the following example of the documentation (pag 11) gets this:

P u t t i n g a node around \ tikzmarknode { t x t }{ some t e x t }
means we can c o n n e c t t e x t t o g e t h e r , i n c l u d i n g i n
maths :
\[
\ tikzmarknode { a }{\sum_{k=1}^n} k ^{\ tikzmarknode {b }{2}}
\]
\ b e g i n { t i k z p i c t u r e } [ remember p i c t u r e , o v e r l a y ]
\draw[−>] ( t x t ) −− ( a ) ;
\draw[−>] ( a . s o u t h ) t o [ out =−90, i n =−45] ( b . s o u t h e a s t ) ;
\end{ t i k z p i c t u r e }

I've tried with other viewers and the same thing happens, I assume that there are several users who copy examples of the documentation to experiment, I think it would be a little more friendly (from my point of view of course). Greetings and Thanks for your great work.

loopspace commented 5 years ago

I've tried implementing the solution from https://tex.stackexchange.com/q/4911/86 in https://github.com/loopspace/tikzmark/commit/f4d37022f5f48a8e32784099760c93c2196272ca

Please test!

pablgonz commented 5 years ago

I've reviewed it and now I can copy and paste from the pdf documentation. I will wait for the official version in ctan. Greetings