Re: emphasizing source code words

2021-02-04 Thread Juan Manuel MacĂ­as
Hi Luca

Luca Ferrari  writes:

> Thanks, but stil Im not able to figure it out. I've searched thru the
> org documentation without any luck.
>
> Luca

To use the minted package as backend (https://www.ctan.org/pkg/minted),
I have in my Emacs:

(setq org-latex-listings 'minted)
  (setq org-latex-minted-options
 '(("frame" "lines") ("linenos=true") ("breaklines")))

You also need to install the Python pigments library on your OS. In
Arch (in my case) is the python-pygments package.

And you have to make sure that when you export to LaTeX it always compiles
with the -shell-escape option. For example:

(setq org-latex-pdf-process
  '("lualatex -shell-escape -interaction nonstopmode -output-directory %o 
%f"
"lualatex -shell-escape -interaction nonstopmode -output-directory %o 
%f"
"lualatex -shell-escape -interaction nonstopmode -output-directory %o 
%f"))

Lastly, in Org docs you need of course to load the minted package:

#+LaTeX_HEADER: \usepackage{minted}

You can see how the highlighting looks like in this post from my blog (in
Spanish): under the title there is a button to download the entry in PDF
version: https://lunotipia.juanmanuelmacias.com/evitar_funcion_lua.html

Finally, you may be interested in this new package that TEC has written:

https://www.reddit.com/r/emacs/comments/lbkmmz/the_best_syntax_highlighting_in_a_pdf_youll_see_a/

Best regards,

Juan Manuel 






Re: emphasizing source code words

2021-02-04 Thread Luca Ferrari
On Mon, Feb 1, 2021 at 1:56 PM TEC  wrote:
> I'd have to look at the manual for specifics, but I know that you can
> highlight lines when using the minted backend.

Thanks, but stil Im not able to figure it out. I've searched thru the
org documentation without any luck.

Luca



Re: emphasizing source code words

2021-02-01 Thread TEC


Luca Ferrari  writes:

> Hi all,
> I'm using org to produce beamer presentations, and I've a lot of src blocks.
> Is there any way to emphasize words or lines within such blocks? For
> example to place the command arguments in bold face?
>
> Thanks,
> Luca

I'd have to look at the manual for specifics, but I know that you can
highlight lines when using the minted backend.

Hope that might be of some help,

--
Timothy.



emphasizing source code words

2021-02-01 Thread Luca Ferrari
Hi all,
I'm using org to produce beamer presentations, and I've a lot of src blocks.
Is there any way to emphasize words or lines within such blocks? For
example to place the command arguments in bold face?

Thanks,
Luca