Lockscreen widget manager

Rating: 
4.25
Your rating: None Average: 4.3 (8 votes)

This is a patch and application that allow the lockscreen to be configured using widget components. The patch modifies the lockscreen files to use the widget items and also removes the clock. The application is used to manage the lockscreen portrait and landscape layouts. Different widgets can be used in each layout. The jolla-clock and other date and times widgets are included in the installation. Full usage instructions on TMO http://talk.maemo.org/showthread.php?p=1491621#post1491621 I have explicitly added conflicts into the spec for v0.2 so this will not install if the following patches are installed:

Calendar events on lockscreen

Lockscreen analog clock

Show weather on lockscreen

This is quite likely to conflict with other lockscreen patches as well. If you do have one of these applied together with the widget manager I would recommend disabling the widget manager patch and checking the following lines: PortraitWidgets {anchors.fill:parent visible: lockScreenPage.isPortrait } LandscapeWidgets {anchors.fill:parent visible: !lockScreenPage.isPortrait } are not in file /usr/share/lipstick-jolla-home-qt5/lockscreen/LockItem.qml before restarting the homescreen or rebooting the phone. Otherwise you may not be able to get to the homescreen.

v0.4 obsoletes the old widgets as they wont work with the new preview functionality. They will be uninstalled. You will need to reinstall the 0.4 compatible ones which have the code to preview.

 

 

Screenshots: 
Application versions: 
AttachmentSizeDate
File widget-manager-0.1-1.noarch.rpm15.75 KB16/12/2015 - 03:28
File widget-manager-0.2-1.noarch.rpm17.65 KB31/03/2016 - 08:34
File widget-manager-0.3-1.noarch.rpm18.86 KB08/05/2017 - 20:49
File widget-manager-0.4-1.noarch.rpm23.42 KB29/09/2017 - 08:41
File widget-manager-0.4-2.noarch.rpm23.68 KB27/10/2017 - 18:39
File widget-manager-0.5-1.noarch.rpm29.36 KB30/05/2019 - 09:31
Changelog: 

0.5
- Starts with current saved widgets and layout. Rotating the phone switches betwen saved portrait and landscape widgets layouts. This will work after you have first saved a layout using version 0.5. Unfortunately this won't restore layouts created with older versions.
- Patch updated to remove weather indicator
0.4-2
- Fixed patch for Kymijoki compatibility
0.4-1
- Implemented preview of the widgets on the arrange widgets screen
- Fine control box draggable from top right corner
- Added switch in settings to turn off anchor based positioning and use x y instead
- Added custom anchor functionality in fine control box to define horizontal and vertical anchoring for each widget
- Added settings to independently change rotation for lpm screen, lock screen and home screen
- Fixed patch for Jämsänjoki compatibility
- Added workaround, now compatible with Ultimate Statusbar patch

0.3
- Implemented a fine control box to move widgets pixel by pixel. Activated by long press.
- Fixed patch for Iijoki compatibility
0.2
- Added gridlines, configurable through settings
- Settings to control lockscreen/homescreen
- Fixed jolla clock animations
- Improved placement algorithm
- Added requirements and conflicts in spec file

0.1
- First build

Comments

levone1's picture

[nemo@Sailfish ~]$ sailfish-qml widgetManager
[D] unknown:0 - Using Wayland-EGL
[W] unknown:0 - Theme dir "/usr/share/themes/jolla/meeg
otouch/z1.25/" does not exist
[D] unknown:0 - Got library name: "/usr/lib/qt5/qml/io
/thp/pyotherside/libpyothersideplugin.so"

Then it launches. Thanks

levone1's picture

Tried a few times on Xperia X Compact, (install, apply, restart home - not working. Unapply, uninstall, refresh, reboot, reinstall, apply - not working, etc). Same every time: installs and opens with no issues or errors, but no widgets can be 'checked' - nothing happens no matter how much I tap or hold or anything, and no widgets appear. I also installed weather widget, and it appears on the list afterwards, but same result.
I don't have any conflicting patches installed, but I tried unapplying all other patches anyway, just in case, but no different.
Any ideas? Thanks

anig's picture

Can you use the terminal to launch widget manager. The command is:
sailfish-qml widgetManager
Let me know what errors are displayed.

dfstorm's picture

The only thing I would had is to be able to edit the media player placement. Now it's at the same place than the native one but too "wide" and it goes over the edge of the screen ^^'

dfstorm's picture

Note : I reloaded preloaded service everytime I modified the patch status in patch mamanger **

dfstorm's picture

Well haha.. I tried it again to give you the error message and it did work. How to repeat: 1- install, 2- apply patch, 3- lauch the app, 4- add widget, edit then save layout, 5- apply with the pull menu. 6- == it trow the error ==. 7 disable the patch in patch manager, 8- go back in the app, edit and save a layout with a widget 9- apply with the pull down menu (reload the homescreen but has no effect). 10- go in patchmanager and enable this patch. 11- reload preloaded service.

And success, your layout show up. And now you can edit and apply like it's intended :)

anig's picture

Thanks I will take a look to see why it is failing the first time.

dfstorm's picture

It don't work for me; sailfish X 3.0.3.10 XA2. Everythings looks okay but I can't "apply" any layout containing a widget. It trow an error. Applying an Empty layout do work... But eh ;) ...everything else (installing the patch, activating it, etc...) do work so nice work anyway ^^'

darbess's picture

I could not make it work on SFOS 3.0.3.9 on Xperia

Historyscholar's picture

me too

anig's picture

Did the patch fail? Or the application doesn't load?

anig's picture

Yes I will work on this again once I've finished a few things for my kids mode app.

Ingvix's picture

Are you planning to update this patch? I'd appreciate if you do.

gaelic's picture

Unfortunately not compatible with 2.1.3 (SailfishX release)

Ingvix's picture

I just realized that because of this patch the statusbar has disappeared from lockscreen on Xperia X. It seem to require a bit more work to get it work right.

EDIT: It was actually quite a simple fix. Here's a working unified_diff.patch: https://pastebin.com/V5ffysVr

Though I noticed that the LockItem seem to be in lower position on Xperia than on Aqua Fish/JollaC so it requires some testing to get the widgets where you want them.

Ingvix's picture

You can replace the unified_diff.patch's content with this to make it work: https://pastebin.com/GAZjneVW

@anig: You could also provide a package for SFX with that patch file.

gaelic's picture

Thanks for the update and the compatiblity with Statusbar Ultimate :D Works purrfekt

Ingvix's picture

Nice to have this functional again and improved again, thanks.

I also thought that the text colors in calendar and weather widgets could also turn to highlight color when Sneak peek kicks in, like the clock already does. The border color in them already seems to do that.

It'd also be nice if when opening the widget manager the current layout would be loaded and the widgets in it already activated and in the their current position when moving to the positioning page. Then it would be easier to make a small fixes like if you want to move just one widget just a little.

Ingvix's picture

I wonder if there's scaling issues or is this somehow designed just for Jolla1 screen specs but on Aqua Fish it goes like this: http://imgur.com/a/hRmkG

EDIT: It would seem that the meecast widget it relative to the bottom of the calendar widget which height changes with the number of calendar entries. That's not a very smart way to do things, is it?

EDIT2: I also edited the patch a bit so that lockscreen can't go upside down which I found annoying especially because home screen didn't do that. So it now shows only default allowed orientations. Also I set it to show sneak peek only in portrait mode as I find it more comfortable that way. The transition between landscape and portrait shows in non-lowpowermode so it's kinda ugly to watch anyway. You may use this in future releases if you wish: https://pastebin.com/BABKC8kp

anig's picture

The whole positioning is based off anchors. So as the calender entries grow the widget below it gets pushed down, rather than overlapping. I could make it optional to switch to x,y positioning and have widget box size the maximum it could be. I will add the orientation change as an option. Thanks for the feedback.

Ingvix's picture

Option for x,y positioning would great, thanks.

If possible, I think the smartest move would be to use the calendar widget's maximum height as the preview box's height when setting the position. Maximum height would be the height of the widget when the maximum amount of calender entries (set in the lockscreen calendar settings page) are present. If this would be shown in the preview, one could more easily set the static position of other widgets.

Also that anchoring assumes that one surely would place the weather widget under the calendar widget which surely would not be the case for all.

EDIT: Well now I feel stupid for not noticing that you just said that maximum height that I described.

Markkyboy's picture

I'm working on something similar but I have no settings, all actions are done from lockscreen, tapping, flicking, holding, etc......I have 4 'widgets' so far; Time, Date, Weather and Calendar, all are linked directly to their respective applications/functions. Long press on the Time takes you to Alarm/Timers page, Date takes you directly to jolla-calendar, weather to sailfish-weather and calendar (repeat) to jolla-calendar. The weather widget can also be tapped to show 5 day forecast in portrait and 8 days in landscape.
All text has a drop shadow behind it (for better visibility on bright wallpapers) as well as a background dimmer with 9 stages to 'dim' the background making the widgets even easier to see!........my main problem is getting the widgets to stay where they are dragged to. Rotate the phone and all widgets have shifted back to their given positions, I need to create a gridview or grid so I can 'drop' the widgets and they stay put no matter of portrait or landscape view.
Nice to see something along the same lines, keep it up! :)

gaelic's picture

Unfortunately this patch is not compatible with the famous: https://openrepos.net/content/ancelad/patch-ultimate-statusbar-patch

Maybe there is a way around the conflicts?

anig's picture

Will see if I can find a work around to avoid the conflict.

Ingvix's picture

I hope you update the position changer with the one you used for Calendar events on lockscreen. I'd also like to have weather widget support if possible. I can't remember right now if this already had a landscape lockscreen support but if not I hope you add that too. The only thing that's been stopping me from having my lockscreen rotating enabled is that the widgets are all messed up.

anig's picture

The position changer was originally developed for this. Do you use Meecast? I have a widget for that, I just need to ask the Meecast developers permission  before releasing it.

Ingvix's picture

Yes, I use Meecast. Is it the same view as the events view widget for Meecast or your own design? I hope you get the permission.

Jatin's picture

Most of the patches are not working in intex aqua fish like this one.

Ingvix's picture

Nice improvements, but I'm still having hard time getting it in the middle by hand. Always when I lift my finger it moves that one pixel to the wrong direction. I found that the best method is to press the power button while holding the widget where I want it. Stick to closest grid line -option would be very helpful.

EDIT: And under that option there could be option if the sticking part would be the middle red lines of the widget or the outlines of the widget. Then I would be happy.

EDIT2: Here's also some problems I encountered: https://imgur.com/a/fppFp

anig's picture

The reason is because I wrote the code to snap to the nearest 2px. I am planning to change that and implement an arrow control box when you long press on a widget, which will allow you to move 1px at a time.

Pages