Nightmode

Various KDE 1.-4. Improvements

Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net

6
Score 80.0%
Description:

Nightmode is a kwin plugin that makes the entire screen darker. The reason behind this for when you are using the laptop at night, either outside or in bed - and find that even on the darkest screen backlight level the screen is way too bright.

The plugin can be turned on or off by a simple key combination, and the amount of dimming can be configured.
Last changelog:

9 years ago

0.2: Added icon made by srog.
0.2: Ubuntu package by srog

tomsdale

9 years ago

Thank you, that worked beautifully. I'll try to get it into the arch user repo but don't know how to package yet :-(.
I'll report back once I found out.

Report

martosurf

9 years ago

This is an incedible useful KWin plugin, KDE SC should ships it as default, best!

Report

C S1

DavidEdmundson

9 years ago

Aww. Thanks :)

Report

mirzaD

9 years ago

it seem that this effect doesn't work without libkwineffects1, eve if libkwineffects1a is installed on ma kubuntu 10.04

compiling from source gives error:

[ 25%] Building CXX object CMakeFiles/kcm_kwin4_effect_nightmode.dir/nightmode_config.o
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp:23:25: error: kwineffects.h: No such file or directory
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp:41: error: expected constructor, destructor, or type conversion before ‘(’ token
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp: In member function ‘virtual void KWin::NightmodeConfig::load()’:
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp:88: error: variable ‘KConfigGroup conf’ has initializer but incomplete type
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp:88: error: ‘EffectsHandler’ has not been declared
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp: In member function ‘virtual void KWin::NightmodeConfig::save()’:
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp:99: error: variable ‘KConfigGroup conf’ has initializer but incomplete type
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp:99: error: ‘EffectsHandler’ has not been declared
/home/mirza/Downloads/Sources/NightMode/nightmode/nightmode_config.cpp:107: error: ‘EffectsHandler’ has not been declared
make[2]: *** [CMakeFiles/kcm_kwin4_effect_nightmode.dir/nightmode_config.o] Error 1
make[1]: *** [CMakeFiles/kcm_kwin4_effect_nightmode.dir/all] Error 2
make: *** [all] Error 2

Report

C S1

DavidEdmundson

9 years ago

It appears more likely to me that you don't have kdebase-workspace-dev installed.

pro tip: any error about "foobar.h" when compiling probably means you're missing a "-dev" package (which contains the header files needed for compilation but not for running)

"apt-file search foobar.h" is quite good for telling you which ones.

Report

C S1

DavidEdmundson

9 years ago

Edit: sorry misread your first comment.

the kwineffects1 vs 1a is the reason the debian package doesn't work.

the deb package needs rebuilding against the newer lib. I hate building packages, and have no idea how to fix it. Pester srog, he's got the skills.

Report

gerlosgm

10 years ago

This is a really useful plugin, at least for me. I'm an amateur astronomer and I always look for ways to preserve my night vision, and your plugin was what I was looking for.

Can you add a feature to add a custom tint (I'd like red, for night vision) when nightmode is on?

It would be really fantastic if we could get features similar to Nocturne app for Mac Os X:
http://docs.blacktree.com/nocturne/nocturne
I used it on my Macbook Pro and loved it (but alway prefer GNU/Linux on Mac Os X).

Report

C S1

DavidEdmundson

10 years ago

Doing these features is a lot more work, kwin has some conveneience functions for setting brightness and saturation. For colour shifting I'd have to do some actual work.

I've got a few projects on the go at the moment, but I'll try and at least have a go - any advice/hints/help from anyone would be appreciated.

Report

gerlosgm

10 years ago

I'm back from a couple of nights of astrophotography with my laptop, and I can confirm that your plugin is really useful to preserve night vision.
I partially solved the color problem choosing the aya plasma theme and setting a dark and red-based color theme.

Thanks for your work! :-)

Report

martosurf

10 years ago

Ok, this is a n00b question, how do I install it?

Report

C S1

DavidEdmundson

10 years ago

If you're on Ubuntu, just follow the ubuntu package links.

Otherwise:

download source
extract

run the following

cd nightmode
mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr
make
sudo make install

Report

Contrast

10 years ago

You might want to add this link to the downloads section: https://launchpad.net/~samrog131/+archive/ppa/+sourcepub/1086403/+listing-archive-extra

Report

C S1

DavidEdmundson

10 years ago

Thanks ever so much. I hate packaging, and this will make it much more accessible.

Any chance you could build up version 0.2. The build should all be the same, except your patch isn't needed.

Report

9

srog

10 years ago

About the PPA (Personal Package Archives for Ubuntu)

Front page with search:
https://launchpad.net/ubuntu/+ppas

Results with the "nightmode":
https://launchpad.net/ubuntu/+ppas?name_filter=nightmode

The "search" may or may not find hits - now it did find two.

Mine, front page (warnings etc):
https://launchpad.net/~samrog131/+archive/ppa

and a closer look:
https://launchpad.net/~samrog131/+archive/ppa/+packages?field.name_filter=nightmode&field.status_filter=published&field.series_filter=

Report

DanaKil

10 years ago

I can't compile it right now but it could be great to allow to darken only a specified window.

It is sometime hard for the eyes when reading a website with a bright background so I use the "dim inactive windows" effect and unfocus the window that I'm reading. Maybe your plugin could bring a more elegant solution to this problem ? (I think it will be better than darken all the screen because not all windows need this effect at the same time, ie Kate with a dark theme and Konqueror with an online documentation site)

Anyway, thanks

Report

C S1

DavidEdmundson

10 years ago

If you can draw or find me an icon I'll be happy to use it.

I'll also happily link to any packages that anyone makes.

Report

Seli

10 years ago

You can easily make a bunch of up-to-date packages yourself: http://kdedevelopers.org/node/4177 .

Report

9

srog

10 years ago

Maybe a modified KDE display (.svgz) icon ?

Licence:
http://websvn.kde.org/branches/KDE/4.4/kdeartwork/IconThemes/primary/LICENSE?view=markup

Nightmode.svg:
http://www.mediafire.com/download.php?yyzne0yronx

Preview (256):
http://yfrog.com/1unightmode256p

In Action:
http://yfrog.com/5gcapturekgp

Report

C S1

DavidEdmundson

10 years ago

That's awesome!

I've implemented it into 0.2, and will push it on here tonight.

Thanks again!

Report

9

srog

10 years ago

Working fine with the Kubuntu 10.04.

Good work !

Maybe an icon for the Nightmode (nightmode.desktop) ?

Report

mirzaD

10 years ago

great thing thank you, I was recently doing workaround with dim inactive window to achieve this :)

Report

cmoh

10 years ago

Thanks for this - I was already using in a clumsy manner the power management applet to achieve this effect. However, the brightness kept changing on power events.

Also, I've attached a Gentoo ebuild for it at http://bugs.gentoo.org/show_bug.cgi?id=317291

Report

9 years ago

0.2: Added icon made by srog.
0.2: Ubuntu package by srog

12345678910
12
product-maker l0ll0lll Jan 23 2015 9 excellent
product-maker bugsbane Aug 01 2011 9 excellent
product-maker svah4cky0 Jan 19 2011 9 excellent
product-maker augegr Jan 18 2011 9 excellent
product-maker SvenArcher Jan 18 2011 9 excellent
product-maker frag Jan 18 2011 9 excellent
product-maker pejakm Jan 18 2011 9 excellent
product-maker srog Jan 18 2011 9 excellent
product-maker nikore90 Jan 18 2011 9 excellent
product-maker TommyCZ Jan 08 2011 9 excellent
product-maker aspotashev Nov 14 2010 9 excellent
product-maker Raboch Sep 22 2010 9 excellent
product-maker Base: 4 x 5.0 Ratings
bugsbane
Aug 01 2011
ub1x
Feb 09 2011
gmsh
Jan 26 2011
tomsdale
Sep 15 2010
michalm
Jun 28 2010
gerlosgm
Jun 10 2010
File (click to download) Version Description PackagetypeArchitecture Downloads Date Filesize DL OCS-Install MD5SUM
*Needs pling-store or ocs-url to install things
Pling
0 Affiliates
Details
license
version
0.2
updated Jan 17 2011
added Apr 25 2010
downloads 24h
0
mediaviews 24h 0
pageviews 24h 3