File featherpad.spec of Package featherpad

#
# spec file for package featherpad
#
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


Name:           featherpad
Version:        @SERVICE@
Release:        0
Summary:        Lightweight Qt Plain-Text Editor for Linux
License:        GPL-3.0-only
Group:          Productivity/Text/Editors
URL:            https://github.com/tsujan/FeatherPad
Source:         %{name}-%{version}.tar.xz
BuildRequires:  cmake
BuildRequires:  gcc-c++
BuildRequires:  hicolor-icon-theme
BuildRequires:  pkgconfig
BuildRequires:  update-desktop-files
BuildRequires:  cmake(Qt6Core) >= 6.2.0
BuildRequires:  cmake(Qt6DBus)
BuildRequires:  cmake(Qt6Gui)
BuildRequires:  cmake(Qt6LinguistTools)
BuildRequires:  cmake(Qt6Network)
BuildRequires:  cmake(Qt6PrintSupport)
BuildRequires:  cmake(Qt6Svg)
BuildRequires:  cmake(Qt6Widgets)
BuildRequires:  pkgconfig(hunspell) >= 1.6
BuildRequires:  pkgconfig(x11)
Recommends:     %{name}-lang = %{version}-%{release}

%description
FeatherPad (by Pedram Pourang, a.k.a. Tsu Jan tsujan2000@gmail.com) is a
lightweight Qt plain-text editor for Linux. It is independent of any
desktop environment and has:
* Drag-and-drop support, including tab detachment and attachment;
* X11 virtual desktop awareness (using tabs on current desktop but opening
  a new window on another);
* An optionally permanent search-bar with a different search entry for each
  tab;
* Instant highlighting of found matches when searching;
* A docked window for text replacement;
* Support for showing line numbers and jumping to a specific line;
* Optional selection highlighting;
* Automatic detection of text encoding as far as possible and optional
  saving with encoding;
* Syntax highlighting for common programming languages;
* Ability to open URLs with appropriate applications;
* Session management;
* Side-pane mode;
* Auto-saving;
* Spell checking with Hunspell;
* Printing;
* Text zooming;
* Appropriate but non-interrupting prompts; and
* Other features that can be found in its settings, on its menus or when it
  is actually used.

%lang_package

%prep
%autosetup

%build
%cmake_qt6
%qt6_build

%install
%qt6_install

%find_lang %{name} --with-qt

%files
%doc ChangeLog NEWS README.md
%{_bindir}/%{name}
%{_bindir}/fpad
%{_datadir}/metainfo/%{name}.metainfo.xml
%{_datadir}/applications/%{name}.desktop
%dir %{_datadir}/%{name}
%{_datadir}/%{name}/help*
%{_datadir}/icons/hicolor/*/apps/%{name}.??g
%license COPYING

%files lang -f %{name}.lang
%dir %{_datadir}/%{name}/translations

%changelog
openSUSE Build Service is sponsored by