diff --git a/applets/binary-clock/package/contents/config/main.xml b/applets/binary-clock/package/contents/config/main.xml --- a/applets/binary-clock/package/contents/config/main.xml +++ b/applets/binary-clock/package/contents/config/main.xml @@ -15,6 +15,9 @@ true + + false + false diff --git a/applets/binary-clock/package/contents/ui/BinaryClock.qml b/applets/binary-clock/package/contents/ui/BinaryClock.qml --- a/applets/binary-clock/package/contents/ui/BinaryClock.qml +++ b/applets/binary-clock/package/contents/ui/BinaryClock.qml @@ -60,6 +60,8 @@ property bool showOffLeds: plasmoid.configuration.showOffLeds property bool showGrid: plasmoid.configuration.showGrid + + property int base: plasmoid.configuration.showBcdFormat? 10:16 property int dots: showSeconds? 6:4 @@ -83,14 +85,12 @@ DotColumn { x:displayLeft y:displayTop - val:hours/10 - startbit:0 + val:hours/base } DotColumn { x:displayLeft+(dotSize+units.smallSpacing) y:displayTop - val:hours%10 - startbit:0 + val:hours%base } @@ -98,30 +98,26 @@ DotColumn { x:displayLeft+(dotSize+units.smallSpacing)*2 y:displayTop - val:minutes/10 - startbit:0 + val:minutes/base } DotColumn { x:displayLeft+(dotSize+units.smallSpacing)*3 y:displayTop - val:minutes%10 - startbit:0 + val:minutes%base } /* seconds */ DotColumn { x:displayLeft+(dotSize+units.smallSpacing)*4 y:displayTop - val:seconds/10 - startbit:0 + val:seconds/base visible:showSeconds } DotColumn { x:displayLeft+(dotSize+units.smallSpacing)*5 y:displayTop - val:seconds%10 - startbit:0 + val:seconds%base visible:showSeconds } diff --git a/applets/binary-clock/package/contents/ui/DotColumn.qml b/applets/binary-clock/package/contents/ui/DotColumn.qml --- a/applets/binary-clock/package/contents/ui/DotColumn.qml +++ b/applets/binary-clock/package/contents/ui/DotColumn.qml @@ -26,29 +26,28 @@ Item { property int val - property int startbit Dot { x:0 y:0 val:parent.val - bit:1<<(startbit+3) + bit:8 } Dot { x:0 y:(dotSize+units.smallSpacing) val:parent.val - bit:1<<(startbit+2) + bit:4 } Dot { x:0 y:2*(dotSize+units.smallSpacing) val:parent.val - bit:1<<(startbit+1) + bit:2 } Dot { x:0 y:3*(dotSize+units.smallSpacing) val:parent.val - bit:1<