Re: Run a GTK application without desktop environment

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello!

No not at all! 

The window manager is just a "helper". Infact the W-window
system was written as a "policyfree" environment. It was a design idea *not to have*
the application dependent on the window - mangager". So this is *not* a strange
thing at all. *NO*! functionality is dependent on the window mangager!

Some programing toolkit are a little bit crippeled to handle itself in
respect with resize, fonts and sutch. Gtk have some issues without
window mangager - but not mutch. If you write a X-window application without
a toolkit you have compleet control. (This is *verry* akward though).

So if you want to write a kiosk there is *no need* to have a window manger.

/gh

Den 2016-03-18 kl. 06:00, skrev Jasper St. Pierre:
> I highly recommend against this. A window manager should be around to
> manage windows, since a lot of functionality to applications is
> provided by the WM. Having it missing could cause strange bugs.
> 
> Please just use a lightweight window manager like Matchbox or metacity.
> 
> On Thu, Mar 17, 2016 at 9:33 PM, Göran Hasse <gorhas@xxxxxxxxxx> wrote:
>> This is quite simple.
>>
>> You have to send in the geometry to the GTK application so that is self
>> can decide its geometry.
>>
>> You don't need any window manager.
>>
>> I run a lot of FreeBSD computers this way.
>>
>> In rc.local you run something like
>>
>> -------------------------------
>> #!/usr/local/bin/bash
>>
>> /usr/sbin/ntpdate -s 0.ubuntu.pool.ntp.org
>>
>> DISPLAY=:0.0
>> export DISPLAY
>>
>> /usr/local/bin/X -ac &
>>
>> # Let the x-server have time to start
>> sleep 20
>>
>> # Connect from any IP
>> /usr/local/bin/xhost + &
>>
>> # Remove the cursor from the screen, turn off screensaver
>> /usr/local/bin/unclutter -root -idle 1 &
>> /usr/local/bin/xset -dpms &
>> /usr/local/bin/xset s off &
>>
>> # set background
>> # https://en.wikipedia.org/wiki/X11_color_names
>> /usr/local/bin/xsetroot -solid Grey &
>>
>> # show local time
>> TZ=CEST
>> export TZ
>>
>> # Startscript for infotable at LEV
>> DISPLAY=192.168.37.88:0.0 ./draw-text -x 0 -y 0 -X 896 -Y 307 -g logo -L "" -f 100 &
>> ...
>>
>> ----------------------------------------------------
>>
>> Note that the gtk-widget have to "resize" itself. So you must program it to
>> read its own "geometry". x , y , X  Y (and some other stuff).
>>
>> /gh
>>
>> Den 2016-03-18 kl. 01:30, skrev Anatol Pomozov:
>>> Hi
>>>
>>> I am trying to implement a simple Kiosk-like web application. The
>>> application will run fullscreen all the time and show web pages. I my
>>> case it will be project's build status. I want to use a simple
>>> computer like a RaspberryPi. And I want to avoid starting heavy
>>> environments like KDE or Gnome.
>>>
>>> Is there any good example/tutorial on this topic?
>>>
>>> In fact I already have a simple GTK application that uses WebKit
>>> engine. I can run it both in Gnome and without it by using xinit. I
>>> have a few questions about it:
>>>
>>> - gtk_window_fullscreen() works fine with Gnome but with xinit it does
>>> not expand the window. Does it mean that fullscreen is actually a DE
>>> feature? What is the best way to make fullscreen app in XWindow? Right
>>> now I use gdk_screen_get_width/height and then set default size.
>>>
>>> - If I run webkit in XWindows it shows pages with horrible fonts. How
>>> to make the browser fonts similar to what I see in my Gnome desktop?
>>> Where to start reading about font handling in the modern Linux
>>> graphical stack?
>>>
>>> - It looks like Kodi player at RaspberryPi does not not use xinit at
>>> all. It looks like RaspberryPi has a direct framebuffer feature. Is it
>>> possible to do it with my webkit-centric application? I can't find any
>>> details on this topic.
>>>
>>> Did anybody make something similar? I would love to hear the
>>> experience in making DE-less applications.
>>> _______________________________________________
>>> gtk-list mailing list
>>> gtk-list@xxxxxxxxx
>>> https://mail.gnome.org/mailman/listinfo/gtk-list
>>>
>>
>> --
>> Göran Hasse
>> Raditex Control AB
>> http://www.rscada.se
>> OrgNr: 556611-8773
>> email: gorhas@xxxxxxxxxx
>> tel: 019-450105
>> mob: 070-5530148
>> _______________________________________________
>> gtk-list mailing list
>> gtk-list@xxxxxxxxx
>> https://mail.gnome.org/mailman/listinfo/gtk-list
> 
> 
> 

-- 
Göran Hasse
Raditex Control AB
http://www.rscada.se
OrgNr: 556611-8773
email: gorhas@xxxxxxxxxx
tel: 019-450105
mob: 070-5530148
_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
https://mail.gnome.org/mailman/listinfo/gtk-list




[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux