LibreOffice: Difference between revisions

From NixOS Wiki
imported>Harärmat
How to make spell check work
Klinger (talk | contribs)
Better beginning (explaining what LibreOffice is). Explain what uno.py is
 
(3 intermediate revisions by 3 users not shown)
Line 1: Line 1:
LibreOffice is a multi-platform Word-processor.
LibreOffice is a multi-platform office suite. It consists of programs for word processing (Writer); creating and editing spreadsheets (Calc), slideshows (Impress), diagrams and drawings (Draw); working with databases (Base); and composing mathematical formulae (Math).


== Spellcheck ==
== Spellcheck ==


In order for spellcheck to work, you will need to install the <code>hunspell</code> as well as the languages that you would like. For example this installs libreoffice with dictionaries for Ukrainian and Central Thai.
In order for spellcheck to work, you will need to install the <code>hunspell</code> package as well as the <code>hunspellDicts.</code> packages for the languages that you would like. For example this installs libreoffice with dictionaries for Ukrainian and Central Thai.


<syntaxHighlight lang=nix>
<syntaxHighlight lang=nix>
Line 14: Line 14:
</syntaxHighlight>
</syntaxHighlight>


== uno Python Library ==
== uno Python Library for API access ==
For getting <code>uno.py</code> python library to work the special path <code>/lib/libreoffice/program</code> needs to be included into the python path as well as the <code>URE_BOOTSTRAP</code> variable must be set.
With <code>uno.py</code> it is possible to access the LibreOffice API with Python. For getting <code>uno.py</code> python library to work the special path <code>/lib/libreoffice/program</code> needs to be included into the python path as well as the <code>URE_BOOTSTRAP</code> variable must be set.


<syntaxHighlight lang=nix>
<syntaxHighlight lang=nix>
let
let
   office = libreoffice-fresh-unwrapped;
   office = pkgs.libreoffice-fresh-unwrapped;
in {
in {
   environment.sessionVariables = {
   environment.sessionVariables = {
Line 29: Line 29:


== KDE / Plasma ==
== KDE / Plasma ==
If you use KDE (Plasma) then you'll be better off with <code>libreoffice-qt</code> package. Otherwise you may lack, e.g. main menu bar.
If you use KDE (Plasma) then you'll be better off with <code>libreoffice-qt</code> package. Otherwise you may lack, e.g. main menu bar.
== See also ==
* [[Onlyoffice]], software suite that offers online and offline tools for document editing, collaboration, and management.


[[Category:Applications]]
[[Category:Applications]]

Latest revision as of 20:19, 18 April 2024

LibreOffice is a multi-platform office suite. It consists of programs for word processing (Writer); creating and editing spreadsheets (Calc), slideshows (Impress), diagrams and drawings (Draw); working with databases (Base); and composing mathematical formulae (Math).

Spellcheck

In order for spellcheck to work, you will need to install the hunspell package as well as the hunspellDicts. packages for the languages that you would like. For example this installs libreoffice with dictionaries for Ukrainian and Central Thai.

  environment.systemPackages = with pkgs; [
    libreoffice-qt
    hunspell
    hunspellDicts.uk_UA
    hunspellDicts.th_TH
  ];

uno Python Library for API access

With uno.py it is possible to access the LibreOffice API with Python. For getting uno.py python library to work the special path /lib/libreoffice/program needs to be included into the python path as well as the URE_BOOTSTRAP variable must be set.

let
  office = pkgs.libreoffice-fresh-unwrapped;
in {
  environment.sessionVariables = {
    PYTHONPATH = "${office}/lib/libreoffice/program";
    URE_BOOTSTRAP = "vnd.sun.star.pathname:${office}/lib/libreoffice/program/fundamentalrc";
  };
}

KDE / Plasma

If you use KDE (Plasma) then you'll be better off with libreoffice-qt package. Otherwise you may lack, e.g. main menu bar.

See also

  • Onlyoffice, software suite that offers online and offline tools for document editing, collaboration, and management.