Many PDF file names are not explicit, but their title is. I was looking for a mean to show PDF title in file explorer column (when using detailed view), I posted on stackexchange but did not found any solution
I was using Thunar, and I changed file explorer to thunar because some python bindings exists. It is Python nautilus project
Just install it, on arch it is python2-nautilus
package
After, you have just to read /usr/share/doc/nautilus-python/README
And check it works adding copying /usr/share/doc/nautilus-python/examples/block-size-column.py
to ~/.local/share/nautilus-python/extensions/
and selectring block-size
in column list
nautilus preferences.
Now I was sure it was possible some custom columns in nautilus detailed view. It was time to show pdf title. I've tested different python packages to get pdf title :
python2-pdfrw
package, it cannot decrypt encrypted titles... see issuepython2-pdfminer.six
, it was very slow to get PDF title for large files, slowing file explorer
I got a simple tool pdfinfo
, it is very fast to get PDF title and shows encrypted title, so I used it from python to get PDF name as you can see in pdf-name-column.py
Very convenient. Here are my notes.
In ubuntu, to install the necessary bindings, simply do
sudo apt install python-nautilus
. This package seems to have been configured for python2, whereas the script above is written for python3. No worries, simply change the lineto
After placing the script in the correct location, you need to restart nautilus. Running
pkill nautilus
and starting it again should do the job. Starting nautilus from the command line will show you any errors from the script, and helps to debug.