Commit Graph

112 Commits

Author SHA1 Message Date
Arnaud Ferraris
e3cebd9da9 [plasmalnf] Adjust explanation message to setup mode
Signed-off-by: Arnaud Ferraris <arnaud.ferraris@collabora.com>
2019-04-08 13:44:41 +02:00
Adriaan de Groot
6071489788 [libcalamaresui] Provide default implementations of next() and back()
- These methods are used for multi-page view-steps, which are rare.
   For all the others, just drop the empty implementation and defer
   to the base class.
2019-02-25 07:49:10 -05:00
Adriaan de Groot
08565b5f17 [libcalamaresui] Remove the signal done() from ViewStep
- The signal is emitted, generally from next(), but not actually used.
2019-02-25 07:34:40 -05:00
Adriaan de Groot
fa08e0ad73 Copyright: fix bad email address 2018-06-15 06:15:43 -04:00
Adriaan de Groot
dd8e53dc22 Copyright: update copyright lines on files touched in 2018
Contributions from:
  Adriaan de Groot <groot@kde.org>
  Gabriel Craciunescu <crazy@frugalware.org>
  AlmAck <gluca86@gmail.com>
  Andrius Štikonas <andrius@stikonas.eu>
  Caio Carvalho <caiojcarvalho@gmail.com>
  Raul Rodrigo Segura <raurodse@gmail.com>
2018-06-15 05:59:11 -04:00
Adriaan de Groot
14fcc2fad6 [plasmalnf] Continue fighting with layout
- The screenshot stays one size, but different ThemeWidgets may overlap
   partially when you shrink the screen or have more than three / four
   themes listed.
 - Probably needs work in the surrounding container and overall better
   page-scrollbar support.
2018-04-13 08:44:02 -04:00
Adriaan de Groot
fa933b9a16 [plasmalnf] Search for theme screenshots
- Search in branding dir, and ., for relative paths,
 - Absolute paths used as-is.
 - Document search as such.
2018-04-10 08:54:47 -04:00
Adriaan de Groot
bfb37e6b37 [plasmalnf] Avoid use of 'uint' 2018-04-09 11:39:45 -04:00
Adriaan de Groot
cb616ec1bb [plasmalnf] Keep fixed size of screenshots (relative to font size) 2018-04-09 11:39:05 -04:00
Adriaan de Groot
5ab01eba9f [plasmalnf] Don't even try to load an empty filename for screenshot.
- Avoid one attempt-to-load if the filename is empty, and one
   re-creating of the Pixmap.
2018-04-09 11:26:43 -04:00
Adriaan de Groot
20e9c2c8e3 Merge branch '3.1.x-stable' 2018-03-29 17:35:36 -04:00
Adriaan de Groot
fb93a8288e [plasmalnf] Simplify showAll handling
- Only need the showAll parameter once, when passing in the list
   of themes to show.
2018-03-29 10:09:45 -04:00
Adriaan de Groot
b0828faadb [plasmalnf] New setting to show all installed LnF themes
- This enables working in three modes:
   - No themes listed; all are shown without screenshots,
   - Themes listed, showAll false; only those are shown,
   - Themes listed, showAll true; the installed-but-not-listed
     themes are shown after the listed ones, and have limited info.
2018-03-29 09:57:19 -04:00
Adriaan de Groot
c2efae765d [plasmalnf] Add auto-detection of Plasma theme.
- Although it's not necessarily accurate for an extensively-modified
   Plasma configuration, we can read the Look-and-Feel from the
   configuration files. Allows auto-detection.
2018-03-29 08:49:22 -04:00
Adriaan de Groot
11652c5856 [plasmalnf] Add pre-selected theme
- For OEM modes where there is already a theme, add a preselect:
   key to pick a specific theme and have that one come up as already-
   selected in the list.
 - Don't re-run the lnftool if an already-selected theme is clicked
   again. Use toggled() instead of clicked().
2018-03-29 07:59:16 -04:00
Adriaan de Groot
94000b6847 [plasmalnf] Improve wording of LnF explanation. 2018-03-29 04:33:55 -04:00
Adriaan de Groot
2f66aa9b07 [plasmalnf] Change to IgnoreAspectRatio
It is the distro's responsibility to produce screenshots that look
good; previously I chose to preserve the aspect ratio on the grounds
that this would keep the look of the screenshot even if the distro
had done one in a weird size. This makes the screenshot part
of the LNF selection look weird, though, since then you get
blank parts.

Switch to ignoring the aspect ration; distro's should produce
screenshots in a 12x8 (i.e. 3:2) aspect ratio, preferrably at
least 120x80 pixels -- but keep in mind hiDPI and the default
font sizes of the distro, which may make other sizes look better.

(this follows discussion with BlueStar Linux)
2018-03-09 11:24:41 -05:00
Adriaan de Groot
04de4a0b02 [plasmalnf] Properly scale the image
- Since the image size isn't known a priori (due to sizing based on fonts),
   load the image and then resize in all code paths.
 - Use the right resizing flags.
 - .. and actually use the resulting scaled pixmap.

Thanks to Jeff Hodd.
2018-02-14 11:23:53 -05:00
Adriaan de Groot
3315df5df1 [modules] Use new convenience logging methods across the board 2018-02-13 11:07:12 +01:00
Adriaan de Groot
6693f81375 [plasmalnf] Document configuration
- Improve documentation, explain necessity of theme: and image: keys
 - Scale screenshot up with font size (numbers picked arbitrarily)
2018-02-12 10:24:33 +01:00
Adriaan de Groot
03dd487fc2 Merge branch '3.1.x-stable' 2017-12-24 16:23:35 -05:00
Adriaan de Groot
661789825a [plasmalnf] Make the module optional
- Check for presence of KDE Frameworks for Plasma & Package
 - Explain when module is skipped
2017-12-24 16:15:04 -05:00
Adriaan de Groot
762ad54344 Documentation: change http links to GitHub to https 2017-12-20 08:39:09 -05:00
Adriaan de Groot
c582ff0d6b Merge branch '3.1.x-stable' 2017-12-20 08:13:55 -05:00
Adriaan de Groot
d5b46dfb86 [plasmalnf] Improve theme-listing handling
- if key is missing or badly typed, enable all (explicitly)
 - document settings and code
2017-12-19 12:51:56 +01:00
Adriaan de Groot
f2aeecf546 [plasmalnf] Improve screenshot view
- make screenies smaller
 - use view-preview to indicate no-screenshot-specified
2017-12-19 12:28:42 +01:00
Adriaan de Groot
10e71bab30 [plasmalnf] Add Breeze 'view-preview' icon for missing screenshots 2017-12-19 12:21:05 +01:00
Adriaan de Groot
e73d54767d [plasmalnf] Expand explanation, drop CSS 2017-12-18 07:57:19 -05:00
Adriaan de Groot
cf39dddbf3 [plasmalnf] Prevent duplicate widgets
- Only create widgets for themes once
 - Update visible texts as needed
2017-12-18 07:25:59 -05:00
Adriaan de Groot
3f258d4bd9 [plasmalnf] Fallback for image-not-found
- calculate a hash of the filename, and use that
 - makes it possible to distinguish different screenshots
   even when the image file is missing / badly configured
 - most colors will be dreadful
2017-12-18 07:07:47 -05:00
Adriaan de Groot
2db485bb33 [plasmalnf] Improve layout of theme widget 2017-12-14 17:04:16 -05:00
Adriaan de Groot
244919d6fe [plasmalnf] Add description to theme widget 2017-12-14 17:01:59 -05:00
Adriaan de Groot
8b3f71af40 [plasmalnf] Widget for showing theme info
- Radio button + group for button action
 - Use a (still very primitive) widget for displaying theme information
2017-12-13 11:04:34 -05:00
Adriaan de Groot
755c0cba18 [plasmalnf] Prep-work for UI changes 2017-12-13 09:55:54 -05:00
Adriaan de Groot
11fc3e0507 [plasmalnf] minor documentation
- Code documentation
 - Add another broken example theme, as test for winnowing
2017-12-13 09:53:41 -05:00
Adriaan de Groot
748ccf94e9 [plasmalnf] Enrich config file
- Extend the config file format to allow theme, image pairs
   as well as just naming the themes.
 - Reduce verbosity when querying Plasma themes.
2017-12-12 06:59:25 -05:00
Adriaan de Groot
6bd8c67ca9 [plasmalnf] Allow filtering the selectable lnf themes
- empty list allows all of them
 - always suppress hidden, invalid themes, and those named
2017-12-04 12:27:30 -05:00
Adriaan de Groot
ad69eda337 [plasmalnf] Complain again if poorly configured 2017-12-04 11:54:33 -05:00
Adriaan de Groot
98b9f67e39 [plasmalnf] Complain more loudly (and more often) when badly configured 2017-12-04 11:51:16 -05:00
Adriaan de Groot
ee979d79ee Merge branch '3.1-pinebook' 2017-12-04 11:45:01 -05:00
Adriaan de Groot
e628ddfdbf [plasmalnf] Try to get back to the live user before changing themes 2017-12-04 09:37:34 -05:00
Adriaan de Groot
b10b19e9ee [plasmalnf] C++ style and reduce includes 2017-12-04 09:11:10 -05:00
Adriaan de Groot
eb92755b0a [plasmalnf] Enable translations
- Move tool-running to the view-step
 - Enable translations by showing name instead of theme-id
 - More verbose logging
2017-12-04 06:40:13 -05:00
Adriaan de Groot
71966b5330 [plasmalnf] Wait longer for the tool to finish 2017-12-03 16:09:34 -05:00
Adriaan de Groot
1de2e94fd0 [plasmalnf] Simplify code, reduce copies of lnftool setting 2017-12-03 15:41:52 -05:00
Adriaan de Groot
fe8ff3ab05 [plasmalnf] Simplify code, remove redundant implementations 2017-12-03 15:34:06 -05:00
Adriaan de Groot
4e2e55a935 [plasmalnf] Needs to run as target user in all cases 2017-12-03 15:24:39 -05:00
Adriaan de Groot
e005c2d02d Merge branch '3.1-pinebook'
- Also document the config file some more.
2017-12-03 15:17:03 -05:00
Adriaan de Groot
ac92d4911d Compatibility: revert conveniences from master 2017-12-03 12:58:54 -05:00
Adriaan de Groot
cddc4699aa [plasmalnf] Import Plasma Look-and-Feel module independently 2017-12-03 12:47:41 -05:00
Adriaan de Groot
388399f256 [plasmalnf] Fix command-line options, run in target user environment 2017-12-03 12:42:44 -05:00
Adriaan de Groot
7e5970324f [plasmalnf] Reset layout along with theme 2017-12-03 11:05:14 -05:00
Adriaan de Groot
81128923e6 [plasmalnf] Disable applying in the target (user|system) for now. 2017-12-03 10:56:39 -05:00
Adriaan de Groot
3bdfa63a79 [plasmalnf] Preserve environment, so that DISPLAY gets to the tool 2017-12-03 10:38:32 -05:00
Adriaan de Groot
d3ef6b07d5 [plasmalnf] Run the lnftool in the target (user|system) 2017-12-03 10:22:46 -05:00
Adriaan de Groot
b3d299bbf1 [plasmalnf] Replace hard-coded path with configurable one 2017-12-03 09:51:13 -05:00
Adriaan de Groot
62623a2376 [plasmalnf] Make an actual job of setting the theme
- Job doesn't actually run lookandfeeltool in the target system yet.
2017-12-03 09:26:59 -05:00
Adriaan de Groot
2d3defcca3 [plasmalnf] Hammer in theme-changing
- Tool is currently a hard-coded path.
2017-12-03 09:18:18 -05:00
Adriaan de Groot
8c65ee5481 [plasmalnf] Get available LNF
- Implement various ways of getting the LNF; the process-based one
   uses a recent CLI-tool from the Plasma developers.
 - Fill the UI with (meaningless) LNF package IDs.
2017-12-03 08:48:41 -05:00
Adriaan de Groot
98d758b4be [plasmalnf] Hammer out the most primitive UI 2017-12-03 07:08:54 -05:00
Adriaan de Groot
41e8fdd362 [plasmalnf] Search for LNF themes like the KCM does 2017-11-01 05:50:04 -04:00
Adriaan de Groot
6c873f0b70 [plasmalnf] Initial stub module 2017-11-01 05:50:04 -04:00