I have set up a Chrome Kiosk using a custom session in X to run Google Chrome.
It generally runs pretty well except except for a screen size issue.
I have a "chrome.desktop" session file saved in /usr/share/xsessions with the following contents.
[Desktop Entry]
Name=Chrome
Comment=This session logs you into Google Chrome
Exec=/usr/share/xsessions/chromeKiosk.sh
Icon=
Type=Application
Encoding=UTF-8
There is also a chromeKiosk.sh file that is used to execute Chrome. It is also in /usr/share/xsessions. The contents are as follows.
#!/bin/bash
while true; do google-chrome http://news.bbc.co.uk --kiosk --start-maximized --disable-restore-background-contents --login-screen-size="1024,768" --disable-translate --disable-new-tab-first-run --enable-vertical-tabs; sleep 5s; done
The problem that I am having is that Google Chrome (or Firefox, or Opera. I have tried various apps), will not maximise to the entire 1024x768 display. It seems to be leaving approximately 1 centimetre of space on the right hand side of the display (I can see the desktop), and also some space at the bottom of the screen.
I have tried this on at least 2 different computers. One had a higher resolution screen. It left an even bigger gap.
It is as if the application that it being run thinks the screen is smaller than it actually is.
Does anybody have any idea what is going on? I am going nuts with this problem.
Here is an image so you can see the border
Google Chrome Kiosk Xsession with odd border
That image is from a screen with a 1280 width.
Not sure why Chrome is doing this, but if you have a look at:
-- you will see
browser.window_placement
and you should see a difference of about 20 pixels between bottom andwork_area_bottom
, and right andwork_area_right
.I edited the values to be the full extents of the display size, and saved Preferences, then chown'd then to
root:root
and chmod'd them to644
so that Chrome (running as thekiosk_user
) cannot modify the settings.I restarted the
kiosk_user
session and tada, Chrome was running full full screen.Hope this helps you.
You are just about to done it... see my codes:
now you need to edit Chrome configuration for user
open location:
~/.config/google-chrome/Default/
and then open
Preferences
.Search for
"browser": {
and modify followings:In my PC I've 1366x768 please adjust as you need.
(you may also add this file in /etc/skel location, this will solve the problem while creating new user you don't need to re-config)