Franco Pasut Web Site

  • it
  • About
  • Contact
  • Posts

Posts

July 19, 2022

Vim and Regular Expressions for removing redundant whitespace

Introduction and structure of the article

I wrote this article to practice “in situ” formula construction of Regular Expressions also called RegEx in Vim.

In particular, the goal is to “clean up” documents with excess whitespace at both the beginning and end of each line.

A basic knowledge of Vim and the Regular Expressions built into the editor is sufficient for understanding the article.

The various formulas are applied to whole documents but, since they are very normal search commands in Vim, they can be applied to individual rows or to specific ranges of rows in the context of the document.

read more
July 11, 2022

Jumping between matching pairs of characters and tags in Vim and Emacs

It is very useful to jump through corresponding pairs of characters, such as parentheses or tags, when coding or writing in a markup language such as HTML, Markdown or LaTeX.

Both Vim and Emacs have dedicated commands for this purpose.

To jump between matching pairs using Vim

Vim uses a “single character” command to jump to the nearest pairs of corresponding characters and to place the cursor into the closing one: %.

read more
May 2, 2022

Text documents: from PDF to vector images

Subject of this article

Recently I needed to convert some documents from PDF format, containing text generated by LaTeX in GNU/Linux operating systems, into vector images.

While avoiding conversion from online services, I basically found three interesting solutions: two in command-line mode (pdf2svg and pdftocairo) and one, very famous, in graphical mode (Inkscape).

In this article I report my evaluations highlighting some differences deriving from the source of the PDF documents and the behaviour of three Linux distributions.

read more
April 8, 2022

LaTeX, three packages for one document

LaTeX, three packages for one document

The standard version of LaTeX has a “state of the art” typographic quality, suitable for any type of document.

For those who want to try different typographical solutions it is, however, possible to use packages that modify the basic settings.

The result may be more or less preferable to the standard version but it is, however, interesting to make some comparative tests.

In this article I compare the title page of an agreement document in the standard version, in the version named koma-script and in the further version named ArsClassica.

read more
February 26, 2022

Vim: copy text directly to the operating system clipboard

Cut and copy in Vim: introduction

As an introduction to the topic regarding the Cut, Copy and Paste functions in Vim you can read a previous article of mine.

The subject of the current article is, instead, a Vim functionality I discovered while reading this page and which is closely related to the previous topic.

Vim can directly redirect cut and copy operations performed on texts to the system memory register (clipboard).

read more
February 9, 2022

Using Emacs to write scores in LilyPond

About LilyPond

LilyPond is a language for producing elegant musical scores, structurally similar to LaTeX with which it can integrate to generate documents containing text and music (for the integration between LilyPond and LaTeX you can read to this article of mine.)

Also in LilyPond, as in LaTeX, you can write the content with various editors.

Very useful, especially to learn the syntax, is the editor called Frescobaldi.

For those who have already learned the syntax, it may be useful, instead, to use the endless potential of Emacs and Vim,

read more
  • ««
  • «
  • 5
  • 6
  • 7
  • 8
  • 9
  • »
  • »»
© Franco Pasut Web Site 2025