View Single Post
Ancelad's Avatar
Posts: 1,552 | Thanked: 3,108 times | Joined on Jun 2012 @ Russia, 96
#1602
Originally Posted by imaginaryenemy View Post
@Ancelad
I am interested in using your script as a bed-side clock when charging. I quickly tried this:
Code:
#!/bin/sh
#call AmberClock.sh color font size
sed -i "/LockScreen MLabelStyle#LockScreenLowPowerModeClockLabel {/,/color/c\\
LockScreen MLabelStyle#LockScreenLowPowerModeClockLabel {\\
    font: \$FONT_FAMILY_"$2" "$3"mm;\\
    color: #"$1";\\
/usr/share/themes/base/meegotouch/libsysuid-screenlock-nokia/style/libsysuid-screenlock-nokia.css
sleep 1 && /sbin/initctl stop xsession/sysuid && sleep 1 && /sbin/initctl start xsession/
Don't try to change other parameters like preferred-size - it is widget style. You should use "1" as parameter $3 in my original script, for example

Code:
sh -c "echo rootme | devel-su -c '/home/user/MyDocs/.AmberClock/AmberClock.sh 000000 light 1'"
And your clock will disappear. Just tested - it works...

Originally Posted by imaginaryenemy View Post
What would be the correct way to add two numbers to these areas? In each parameter there is a negative (-) and the other is a positive (+). As it appears above, all negative numbers can be the same as each other, and all positives can be the same as each other.
Thanks!
Negative ("-1" value only) means "don't change size" (CSS), positive - it will have size you've set up (32px or 3.2mm for example - 1mm~10px).
 

The Following User Says Thank You to Ancelad For This Useful Post: