Giter Site home page Giter Site logo

derat / xsettingsd Goto Github PK

View Code? Open in Web Editor NEW
227.0 10.0 12.0 89 KB

Moved to codeberg.org/derat/xsettingsd

Home Page: https://codeberg.org/derat/xsettingsd

License: BSD 3-Clause "New" or "Revised" License

Python 2.53% C++ 92.58% Roff 2.73% CMake 2.16%
cpp linux x11 xsettings

xsettingsd's Introduction

xsettingsd's People

Contributors

a17r avatar bremner avatar codemage avatar derat avatar eszlari avatar ishanjain28 avatar philmiller avatar quantenzitrone avatar sthen avatar xtaran avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

xsettingsd's Issues

dump_xsettings produces settings that xsettingsd can't parse

Original issue 2 created by derat on 2014-05-19T12:47:09.000Z:

On my system, dump_xsettings generates the line:

Gtk/RecentFilesMaxAge -1

which causes xsettingsd to bomb out with the error:

xsettingsd: Unable to parse ~/.xsettingsd 1: Got invalid setting value

Package from current Debian unstable - Version: 0.0.20121210+72+g474f18a-1

Compile errors

Original issue 1 created by derat on 2009-12-07T17:01:15.000Z:

/usr/local/src/xsettingsd# scons xsettingsd dump_xsettings
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
g++ -o xsettingsd.o -c -Wall -Werror xsettingsd.cc
xsettingsd.cc: In function ‘int main(int, char*)’:
xsettingsd.cc:51: error: ‘stderr’ was not declared in this scope
xsettingsd.cc:51: error: ‘fprintf’ was not declared in this scope
xsettingsd.cc:57: error: ‘stderr’ was not declared in this scope
xsettingsd.cc:57: error: ‘fprintf’ was not declared in this scope
xsettingsd.cc:67: error: ‘stderr’ was not declared in this scope
xsettingsd.cc:67: error: ‘fprintf’ was not declared in this scope
scons: *
* [xsettingsd.o] Error 1
scons: building terminated because of errors.

/usr/local/src/xsettingsd# scons dump_xsettings
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
g++ -o dump_xsettings.o -c -Wall -Werror dump_xsettings.cc
g++ -o common.o -c -Wall -Werror common.cc
g++ -o config_parser.o -c -Wall -Werror config_parser.cc
config_parser.cc: In destructor ‘virtual
xsettingsd::ConfigParser::FileCharStream::~FileCharStream()’:
config_parser.cc:181: error: ‘fclose’ was not declared in this scope
config_parser.cc: In member function ‘virtual bool
xsettingsd::ConfigParser::FileCharStream::InitImpl(std::string_)’:
config_parser.cc:188: error: ‘fopen’ was not declared in this scope
config_parser.cc: In member function ‘virtual bool
xsettingsd::ConfigParser::FileCharStream::AtEOFImpl()’:
config_parser.cc:201: error: ‘EOF’ was not declared in this scope
config_parser.cc: In member function ‘virtual char
xsettingsd::ConfigParser::FileCharStream::GetCharImpl()’:
config_parser.cc:206: error: ‘fgetc’ was not declared in this scope
config_parser.cc: In member function ‘void
xsettingsd::ConfigParser::SetErrorF(const char_, ...)’:
config_parser.cc:513: error: ‘vsnprintf’ was not declared in this scope
scons: *** [config_parser.o] Error 1
scons: building terminated because of errors.

Release

Hi,

For easier distro packing it would be useful if xsettingsd had a release/tag. It seems the code has stabilized for some time as well.

Thanks for xsettingsd,
Alad

locate, test and add more avilable xsettings as documentation

I have read the Xsettings Freedesktop Specification and am not really able to find documentation about available settings online.

The specification states:

Names beginning with 'Net/' and case variants of that string are reserved and must not be used without prior agreement.

But there is no documentation on how or where to find or do these agreements.

I also get that everything else is depending on the specific Application(-framework) and i can likely find documentation there.
For example the GTK settings from the documentation can probably be translated directly, by changing the first - to a / and converting the rest to UpperCamelCase/PascalCase.
But I am also a bit lost there: What about Xft? Xft stands for X font library and the only documentation i can find is the Freedesktop Specification. The GTK documentation only provides the options, that are already in the Wiki. Unless I or someone else finds anything else, I'll just guess that's it.

I'm sorry if this not the right place for asking this.

Request for a GUI

It would be very interesting to have a GUI for editing the settings and previewing them.

Any chance of adding one?

Cursor theme changes

Thanks for xsettingsd, has been really helpful in making theme changes/reloads in a WM environment (XMonad currently, for me)!

One setting which seems funky is Gtk/CursorThemeName: upon changing and sending HUP to xsettingsd, the mouse cursor theme does change, but not everywhere. Perhaps this is more of a GTK or X thing? So most programs will update the cursor theme, but not over root (background).

However, if I open lxappearance, without changing anything just opening the program, the mouse cursor is updated. Perhaps it is a GTK/X thing, as current emacs needs a manual set-mouse-color to pickup the change, but not in newer pgtk builds. Not sure how this should work for the mouse theme on the desktop in general, or what lxappearance is doing. My quick look at the code just shows it loading current settings, but via g_object stuff (sorry, not a GTK person to know what's happening).

Is this something that xsettingsd can fix? Or is this something for the WM? Not sure what lxappearance has to do with it, but seems to be a clue that settings need some reload/refresh?

opening apps slowly (Cannot transform xsetting)

some apps open slowly (like clion, and all JetBrains IDEs)
firefox doesn't open

when opening clion from terminal there is an error with gtk, xsetting

(java:122099): Gdk-WARNING **: 11:39:40.090: Cannot transform xsetting gtk-xft-dpi of type gchararray to type gint


(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14750:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14756:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14762:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14768:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14774:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14780:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14786:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:39:40.106: Theme parsing error: gtk.css:14792:20: Not a valid image

(java:122099): Gdk-WARNING **: 11:39:40.142: Cannot transform xsetting gtk-xft-dpi of type gchararray to type gint


(java:122099): Gdk-WARNING **: 11:39:40.142: Cannot transform xsetting gtk-enable-input-feedback-sounds of type gchararray to type gboolean


(java:122099): Gdk-WARNING **: 11:39:40.142: Cannot transform xsetting gtk-enable-event-sounds of type gchararray to type gboolean


(java:122099): Gdk-WARNING **: 11:39:40.143: Cannot transform xsetting gtk-enable-input-feedback-sounds of type gchararray to type gboolean


(java:122099): Gtk-WARNING **: 11:41:40.485: Theme parsing error: gtk.css:14750:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:41:40.485: Theme parsing error: gtk.css:14756:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:41:40.485: Theme parsing error: gtk.css:14762:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:41:40.485: Theme parsing error: gtk.css:14768:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:41:40.485: Theme parsing error: gtk.css:14774:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:41:40.485: Theme parsing error: gtk.css:14780:20: Not a valid image

(java:122099): Gtk-WARNING **: 11:41:40.485: Theme parsing error: gtk.css:14786:20: Not a valid image

firefox

(firefox:183358): Gdk-WARNING **: 11:47:23.536: Cannot transform xsetting gtk-xft-dpi of type gchararray to type gint


(firefox:183358): Gtk-WARNING **: 11:47:23.564: Theme parsing error: gtk.css:14750:20: Not a valid image

(firefox:183358): Gtk-WARNING **: 11:47:23.564: Theme parsing error: gtk.css:14756:20: Not a valid image

(firefox:183358): Gtk-WARNING **: 11:47:23.564: Theme parsing error: gtk.css:14762:20: Not a valid image

(firefox:183358): Gtk-WARNING **: 11:47:23.565: Theme parsing error: gtk.css:14768:20: Not a valid image

(firefox:183358): Gtk-WARNING **: 11:47:23.565: Theme parsing error: gtk.css:14774:20: Not a valid image

(firefox:183358): Gtk-WARNING **: 11:47:23.565: Theme parsing error: gtk.css:14780:20: Not a valid image

(firefox:183358): Gtk-WARNING **: 11:47:23.565: Theme parsing error: gtk.css:14786:20: Not a valid image

(firefox:183358): Gtk-WARNING **: 11:47:23.565: Theme parsing error: gtk.css:14792:20: Not a valid image

(firefox:183358): Gdk-WARNING **: 11:47:23.630: Cannot transform xsetting gtk-xft-dpi of type gchararray to type gint


(firefox:183358): Gdk-WARNING **: 11:47:23.631: Cannot transform xsetting gtk-enable-input-feedback-sounds of type gchararray to type gboolean


(firefox:183358): Gdk-WARNING **: 11:47:23.631: Cannot transform xsetting gtk-enable-event-sounds of type gchararray to type gboolean


(firefox:183358): Gdk-WARNING **: 11:47:23.636: Cannot transform xsetting gtk-enable-input-feedback-sounds of type gchararray to type gboolean

CharStreamTest.Basic test failure

Hi,

Building the latest release with CMake, I see the following test failure:

starting phase `check'                                                                                                                                                                                              
Running tests...                                                                                                                                                            
/gnu/store/j65q3aw414010gdfvmsynwpzfb2jyyd3-cmake-minimal-3.21.4/bin/ctest --force-new-ctest-process                                                                                                                
Test project /tmp/guix-build-xsettingsd-1.0.2.drv-0/build                                                                                                                                                           
      Start  1: CommonTest.SplitString                                                                                                                                                                              
 1/14 Test  #1: CommonTest.SplitString ................   Passed    0.01 sec                                                                                                                                        
      Start  2: CommonTest.GetPadding                                                                     lo                                                                                                        
 2/14 Test  #2: CommonTest.GetPadding .................   Passed    0.00 sec                                                                                                                                        
      Start  3: CommonTest.GetDefaultConfigFilePath                                                                                                                                                                 
 3/14 Test  #3: CommonTest.GetDefaultConfigFilePath ...   Passed    0.00 sec                                                                                                                                        
      Start  4: CharStreamTest.Basic                                                                                                                                                                                
 4/14 Test  #4: CharStreamTest.Basic ..................***Failed    0.00 sec                                                                                                                                        
Note: Google Test filter = CharStreamTest.Basic                                                                                                                                                                     
[==========] Running 1 test from 1 test suite.                                                            lo                                                                                                        
[----------] Global test environment set-up.                                                                                                                                                                        
[----------] 1 test from CharStreamTest                                                                                                                                                                             
[ RUN      ] CharStreamTest.Basic
/tmp/guix-build-xsettingsd-1.0.2.drv-0/source/config_parser_test.cc:25: Failure
Death test: stream.AtEOF()
    Result: failed to die.                                                                                de
 Error msg:
[  DEATH   ]                                                                                              ss
[  FAILED  ] CharStreamTest.Basic (0 ms)
[----------] 1 test from CharStreamTest (0 ms total)

[----------] Global test environment tear-down
[==========] 1 test from 1 test suite ran. (0 ms total)                                                   de
[  PASSED  ] 0 tests.
[  FAILED  ] 1 test, listed below:                                                                        ss
[  FAILED  ] CharStreamTest.Basic

 1 FAILED TEST

      Start  5: CharStreamTest.LineNumbers
 5/14 Test  #5: CharStreamTest.LineNumbers ............   Passed    0.00 sec
      Start  6: ConfigParserTest.ReadSettingName
 6/14 Test  #6: ConfigParserTest.ReadSettingName ......   Passed    0.00 sec
      Start  7: ConfigParserTest.ReadInteger
 7/14 Test  #7: ConfigParserTest.ReadInteger ..........   Passed    0.00 sec
      Start  8: ConfigParserTest.ReadString                                                               lo
 8/14 Test  #8: ConfigParserTest.ReadString ...........   Passed    0.00 sec
      Start  9: ConfigParserTest.ReadColor
 9/14 Test  #9: ConfigParserTest.ReadColor ............   Passed    0.00 sec
      Start 10: ConfigParserTest.Parse
10/14 Test #10: ConfigParserTest.Parse ................   Passed    0.00 sec
      Start 11: IntegerSettingTest.Write
11/14 Test #11: IntegerSettingTest.Write ..............   Passed    0.00 sec                              lo
      Start 12: StringSettingTest.Write
12/14 Test #12: StringSettingTest.Write ...............   Passed    0.00 sec
      Start 13: ColorSettingTest.Write
13/14 Test #13: ColorSettingTest.Write ................   Passed    0.00 sec
      Start 14: SettingTest.Serials
14/14 Test #14: SettingTest.Serials ...................   Passed    0.00 sec

93% tests passed, 1 tests failed out of 14

Total Test time (real) =   0.06 sec
                                                                                                          lo
The following tests FAILED:
          4 - CharStreamTest.Basic (Failed)
Errors while running CTest
make: *** [Makefile:117: test] Error 8

Test suite failed, dumping logs.
error: in phase 'check': uncaught exception:
%exception #<&invoke-error program: "make" arguments: ("test" "-j" "4") exit-status: 2 term-signal: #f stolop-signal: #f> 
phase `check' failed after 0.2 seconds
command "make" "test" "-j" "4" failed with status 2

I've built the project with the -DBUILD_TESTING=ON CMake configure flag.

Thank you!

Load settings from different config file

So, i was thinking if it is possible to load settings from a different file (let's say ~/.config/xsettingsd) rather than ~/.xsettingsd

(So we can have different look and feel in each window manager)

Something like : xsettingsd --config ~/.config/xsettingsd

Cursor size in OpenBox

Hello,
I change the cursor size but it seems openbox ignore it while with xfsettingsd it works properly.
May be using "Gtk/CursorThemeSize" is not the right option.

New release?

Now with a complete cmake build system merged (and a systemd unit added), I think it would make sense to tag a new release.

404 for https://developer.gnome.org/gtk/unstable/GtkSettings.html

Getting a 404 when I tried to open it.

I found this: https://developer-old.gnome.org/gtk3/stable/GtkSettings.html
Looking at https://developer.gnome.org/gtk/unstable/GtkSettings.html (with Wayback Machine: https://web.archive.org/web/20210507005358/http://developer.gnome.org/gtk3/unstable/GtkSettings.html), it seems that it's the same page moved to a different address.

Or how about this? https://docs.gtk.org/gtk3/class.Settings.html. I find this one is not a single page like the two links above, which I don't prefer.

Thoughts?

Changing font type/size?

I can't seem to find the option to configure gtk-font-name. I think it would be nice to have.
Something like:
Net/FontName 'Ubuntu 12'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.