Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Fullscreen application in Ubuntu
QtWS25 Last Chance

Fullscreen application in Ubuntu

Scheduled Pinned Locked Moved Solved General and Desktop
11 Posts 4 Posters 7.9k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    bask185
    wrote on 11 Jul 2017, 14:31 last edited by
    #1

    I am having troubles with getting rid of the Ubuntu desktop environment.

    Eventually I tried

    MainWindow::showFullScreen();
    

    which did the thing but! As soon as I open a different window like my keyboard or settings menu. The desktop comes back. And I don't want my keyboard to be fullscreen.

    Is there a way to prevent the desktop from popping up?

    1 Reply Last reply
    0
    • A artwaw
      12 Jul 2017, 10:51

      @bask185
      Hi,
      as for serial port access it is rather system problem than Qt. I personally detest *buntu distros for many reasons but from top of my head:

      1. if you have modemmanager installed - that may cause problems with unrestricted access;
      2. user account that tries to access serial ports has to be a member of appropriate group, as far as I remember on Ubuntu it was dialout.

      Secondly - to gain the output properly have you thought about dumping all the output to dedicated log file?
      As for shutdown and similar - there is a console tool named htop which is a very handy process manager. For the sake of management I would suggest rather writing a simple console control program that would communicate with the main one to request restart/shutdown etc.

      But again - that is just from the top of my head and may not be accurate since I do not know your exact use case and system config.

      Cheers

      B Offline
      B Offline
      bask185
      wrote on 12 Jul 2017, 11:48 last edited by
      #10

      @artwaw said in Fullscreen application in Ubuntu:

      @bask185
      Hi,
      as for serial port access it is rather system problem than Qt. I personally detest *buntu distros for many reasons but from top of my head:

      1. if you have modemmanager installed - that may cause problems with unrestricted access;
      2. user account that tries to access serial ports has to be a member of appropriate group, as far as I remember on Ubuntu it was dialout.

      Secondly - to gain the output properly have you thought about dumping all the output to dedicated log file?
      As for shutdown and similar - there is a console tool named htop which is a very handy process manager. For the sake of management I would suggest rather writing a simple console control program that would communicate with the main one to request restart/shutdown etc.

      But again - that is just from the top of my head and may not be accurate since I do not know your exact use case and system config.

      Cheers

      @jsulm said in Fullscreen application in Ubuntu:

      @bask185 Actually there should be a user group having access to serial port. Can you post the output of

      ls -lh /dev/tty*
      

      ?
      If there is such a group than just add your user to it (see /etc/group). Then there is no need for chmod.

      I added myself to 'dialout' and it actually works :D I will do the same on my work PC as well. I added the chmod to .basrc so every time I open up the terminal I must enter my passwd or Ctrl C out it :D

      As for the other part, I suppose I have to use a log file. I mean I still get to scp it to my work PC and acces it on the panel PC as well. And his has as bonus effect that the 'history' is longer than the CLI's :D

      Gents, I call this day a win!

      A 1 Reply Last reply 12 Jul 2017, 11:55
      1
      • M Offline
        M Offline
        mrjj
        Lifetime Qt Champion
        wrote on 11 Jul 2017, 14:41 last edited by
        #2

        Hi
        It depends on what windows manager you are using.
        Some will allow , some will not.
        Unity did not work for me in this regards.

        What is the use case ?

        1 Reply Last reply
        1
        • B Offline
          B Offline
          bask185
          wrote on 12 Jul 2017, 06:20 last edited by bask185 7 Dec 2017, 07:00
          #3

          Ehm the default environment of 16.04 LTS. Which should I download?

          EDIT:
          With the Raspberry PI (Raspbian) I never had this problem because... there was no window manager. It had as disadvantage that I had to give sub menus different colors so they would not 'merge' with the mainwindow but the advantages were great, you could not move the sub-menus (a pro for my device).

          I don't know how these window managers work or how I can remove/turn it of?

          M 1 Reply Last reply 12 Jul 2017, 07:46
          0
          • B bask185
            12 Jul 2017, 06:20

            Ehm the default environment of 16.04 LTS. Which should I download?

            EDIT:
            With the Raspberry PI (Raspbian) I never had this problem because... there was no window manager. It had as disadvantage that I had to give sub menus different colors so they would not 'merge' with the mainwindow but the advantages were great, you could not move the sub-menus (a pro for my device).

            I don't know how these window managers work or how I can remove/turn it of?

            M Offline
            M Offline
            mrjj
            Lifetime Qt Champion
            wrote on 12 Jul 2017, 07:46 last edited by
            #4

            @bask185

            Hi
            What you seems to want is kiosk mode.
            Then only your app runs. nothing else.

            https://askubuntu.com/questions/132262/booting-in-kiosk-mode

            If this is not what you want, please take the time to explain what your app does
            and why you want to run it in full screen and block menu etc.

            regarding the window manager
            https://en.wikipedia.org/wiki/Window_manager

            B 1 Reply Last reply 12 Jul 2017, 09:05
            0
            • M mrjj
              12 Jul 2017, 07:46

              @bask185

              Hi
              What you seems to want is kiosk mode.
              Then only your app runs. nothing else.

              https://askubuntu.com/questions/132262/booting-in-kiosk-mode

              If this is not what you want, please take the time to explain what your app does
              and why you want to run it in full screen and block menu etc.

              regarding the window manager
              https://en.wikipedia.org/wiki/Window_manager

              B Offline
              B Offline
              bask185
              wrote on 12 Jul 2017, 09:05 last edited by bask185 7 Dec 2017, 09:26
              #5

              @mrjj
              My app wil be used on a touch panel PC. This PC will serve as a Human Machine Interface and will communicate with certain machines over it's serial port.

              The kiosk mode seems a rather difficult solution. The machine must boot automatically to the app but from what I see of that kiosk mode you cannot even acces the CLI. And I would need an extra user account to keep root acces. And I am not seeing guarantees that I won't be seeing the grey bar on top of the screen. If that one would be removed, can I than even log out??

              I'd prefer a different solution like disabling the window manager or installing a different desktop environment. And I don't know if Qt happens to have a simple solution similar.

              alt text
              alt text
              http://i394.photobucket.com/albums/pp24/Sebastiaan_Knippels/less_fullscreen_zpsere3jclw.png?t=1499763809

              EDIT: I've solved the problem with thanks to the ubuntu forum. I got directed at this link:
              Start ubuntu without a desktop environment but start an X application

              Anyways tnx for your help mrjj

              M 1 Reply Last reply 12 Jul 2017, 09:39
              1
              • B bask185
                12 Jul 2017, 09:05

                @mrjj
                My app wil be used on a touch panel PC. This PC will serve as a Human Machine Interface and will communicate with certain machines over it's serial port.

                The kiosk mode seems a rather difficult solution. The machine must boot automatically to the app but from what I see of that kiosk mode you cannot even acces the CLI. And I would need an extra user account to keep root acces. And I am not seeing guarantees that I won't be seeing the grey bar on top of the screen. If that one would be removed, can I than even log out??

                I'd prefer a different solution like disabling the window manager or installing a different desktop environment. And I don't know if Qt happens to have a simple solution similar.

                alt text
                alt text
                http://i394.photobucket.com/albums/pp24/Sebastiaan_Knippels/less_fullscreen_zpsere3jclw.png?t=1499763809

                EDIT: I've solved the problem with thanks to the ubuntu forum. I got directed at this link:
                Start ubuntu without a desktop environment but start an X application

                Anyways tnx for your help mrjj

                M Offline
                M Offline
                mrjj
                Lifetime Qt Champion
                wrote on 12 Jul 2017, 09:39 last edited by
                #6

                @bask185
                ok super.
                that is similar to kiosk mode but less restricted.

                ps. all your images shows as
                alt text

                B 1 Reply Last reply 12 Jul 2017, 10:20
                0
                • M mrjj
                  12 Jul 2017, 09:39

                  @bask185
                  ok super.
                  that is similar to kiosk mode but less restricted.

                  ps. all your images shows as
                  alt text

                  B Offline
                  B Offline
                  bask185
                  wrote on 12 Jul 2017, 10:20 last edited by
                  #7

                  @mrjj

                  Meh, I ran into 2 new problems :-(

                  The first problem is that I cannot set up a serial connection. I know that this is because the serial ports (atleast the USb port) have no permissions. As I launch the app via a shellscript I added a line of code before the app starts. I added

                  sudo chmod 777 /dev/tty*
                  

                  If I boot to the normal desktop and run this shellscript I need to enter my password and it works. Than I can log out and log into the GUI desktop and then it can set up a connection. But if booting to the GUI desktop is the first thing of the day, it won't set up a serial connection. So that is a problem. I just have to fill in the damned password before I can connect.

                  The second problem is that I have no longer an output on the CLI. If I run into a bug I need to be able to see the last transfer on the CLI to find the bug. I also need to be able to close the app and restart it via SSH so I can have the debug texts on my work PC. But this also cannot be done.

                  And I don't know why these images won't get shown. I used photobucket like I always do. I see that I left a URL below the 2nd image, perhaps can you click that one?

                  A J 2 Replies Last reply 12 Jul 2017, 10:51
                  0
                  • B bask185
                    12 Jul 2017, 10:20

                    @mrjj

                    Meh, I ran into 2 new problems :-(

                    The first problem is that I cannot set up a serial connection. I know that this is because the serial ports (atleast the USb port) have no permissions. As I launch the app via a shellscript I added a line of code before the app starts. I added

                    sudo chmod 777 /dev/tty*
                    

                    If I boot to the normal desktop and run this shellscript I need to enter my password and it works. Than I can log out and log into the GUI desktop and then it can set up a connection. But if booting to the GUI desktop is the first thing of the day, it won't set up a serial connection. So that is a problem. I just have to fill in the damned password before I can connect.

                    The second problem is that I have no longer an output on the CLI. If I run into a bug I need to be able to see the last transfer on the CLI to find the bug. I also need to be able to close the app and restart it via SSH so I can have the debug texts on my work PC. But this also cannot be done.

                    And I don't know why these images won't get shown. I used photobucket like I always do. I see that I left a URL below the 2nd image, perhaps can you click that one?

                    A Offline
                    A Offline
                    artwaw
                    wrote on 12 Jul 2017, 10:51 last edited by
                    #8

                    @bask185
                    Hi,
                    as for serial port access it is rather system problem than Qt. I personally detest *buntu distros for many reasons but from top of my head:

                    1. if you have modemmanager installed - that may cause problems with unrestricted access;
                    2. user account that tries to access serial ports has to be a member of appropriate group, as far as I remember on Ubuntu it was dialout.

                    Secondly - to gain the output properly have you thought about dumping all the output to dedicated log file?
                    As for shutdown and similar - there is a console tool named htop which is a very handy process manager. For the sake of management I would suggest rather writing a simple console control program that would communicate with the main one to request restart/shutdown etc.

                    But again - that is just from the top of my head and may not be accurate since I do not know your exact use case and system config.

                    Cheers

                    For more information please re-read.

                    Kind Regards,
                    Artur

                    B 1 Reply Last reply 12 Jul 2017, 11:48
                    1
                    • B bask185
                      12 Jul 2017, 10:20

                      @mrjj

                      Meh, I ran into 2 new problems :-(

                      The first problem is that I cannot set up a serial connection. I know that this is because the serial ports (atleast the USb port) have no permissions. As I launch the app via a shellscript I added a line of code before the app starts. I added

                      sudo chmod 777 /dev/tty*
                      

                      If I boot to the normal desktop and run this shellscript I need to enter my password and it works. Than I can log out and log into the GUI desktop and then it can set up a connection. But if booting to the GUI desktop is the first thing of the day, it won't set up a serial connection. So that is a problem. I just have to fill in the damned password before I can connect.

                      The second problem is that I have no longer an output on the CLI. If I run into a bug I need to be able to see the last transfer on the CLI to find the bug. I also need to be able to close the app and restart it via SSH so I can have the debug texts on my work PC. But this also cannot be done.

                      And I don't know why these images won't get shown. I used photobucket like I always do. I see that I left a URL below the 2nd image, perhaps can you click that one?

                      J Offline
                      J Offline
                      jsulm
                      Lifetime Qt Champion
                      wrote on 12 Jul 2017, 11:24 last edited by
                      #9

                      @bask185 Actually there should be a user group having access to serial port. Can you post the output of

                      ls -lh /dev/tty*
                      

                      ?
                      If there is such a group than just add your user to it (see /etc/group). Then there is no need for chmod.

                      https://forum.qt.io/topic/113070/qt-code-of-conduct

                      1 Reply Last reply
                      1
                      • A artwaw
                        12 Jul 2017, 10:51

                        @bask185
                        Hi,
                        as for serial port access it is rather system problem than Qt. I personally detest *buntu distros for many reasons but from top of my head:

                        1. if you have modemmanager installed - that may cause problems with unrestricted access;
                        2. user account that tries to access serial ports has to be a member of appropriate group, as far as I remember on Ubuntu it was dialout.

                        Secondly - to gain the output properly have you thought about dumping all the output to dedicated log file?
                        As for shutdown and similar - there is a console tool named htop which is a very handy process manager. For the sake of management I would suggest rather writing a simple console control program that would communicate with the main one to request restart/shutdown etc.

                        But again - that is just from the top of my head and may not be accurate since I do not know your exact use case and system config.

                        Cheers

                        B Offline
                        B Offline
                        bask185
                        wrote on 12 Jul 2017, 11:48 last edited by
                        #10

                        @artwaw said in Fullscreen application in Ubuntu:

                        @bask185
                        Hi,
                        as for serial port access it is rather system problem than Qt. I personally detest *buntu distros for many reasons but from top of my head:

                        1. if you have modemmanager installed - that may cause problems with unrestricted access;
                        2. user account that tries to access serial ports has to be a member of appropriate group, as far as I remember on Ubuntu it was dialout.

                        Secondly - to gain the output properly have you thought about dumping all the output to dedicated log file?
                        As for shutdown and similar - there is a console tool named htop which is a very handy process manager. For the sake of management I would suggest rather writing a simple console control program that would communicate with the main one to request restart/shutdown etc.

                        But again - that is just from the top of my head and may not be accurate since I do not know your exact use case and system config.

                        Cheers

                        @jsulm said in Fullscreen application in Ubuntu:

                        @bask185 Actually there should be a user group having access to serial port. Can you post the output of

                        ls -lh /dev/tty*
                        

                        ?
                        If there is such a group than just add your user to it (see /etc/group). Then there is no need for chmod.

                        I added myself to 'dialout' and it actually works :D I will do the same on my work PC as well. I added the chmod to .basrc so every time I open up the terminal I must enter my passwd or Ctrl C out it :D

                        As for the other part, I suppose I have to use a log file. I mean I still get to scp it to my work PC and acces it on the panel PC as well. And his has as bonus effect that the 'history' is longer than the CLI's :D

                        Gents, I call this day a win!

                        A 1 Reply Last reply 12 Jul 2017, 11:55
                        1
                        • B bask185
                          12 Jul 2017, 11:48

                          @artwaw said in Fullscreen application in Ubuntu:

                          @bask185
                          Hi,
                          as for serial port access it is rather system problem than Qt. I personally detest *buntu distros for many reasons but from top of my head:

                          1. if you have modemmanager installed - that may cause problems with unrestricted access;
                          2. user account that tries to access serial ports has to be a member of appropriate group, as far as I remember on Ubuntu it was dialout.

                          Secondly - to gain the output properly have you thought about dumping all the output to dedicated log file?
                          As for shutdown and similar - there is a console tool named htop which is a very handy process manager. For the sake of management I would suggest rather writing a simple console control program that would communicate with the main one to request restart/shutdown etc.

                          But again - that is just from the top of my head and may not be accurate since I do not know your exact use case and system config.

                          Cheers

                          @jsulm said in Fullscreen application in Ubuntu:

                          @bask185 Actually there should be a user group having access to serial port. Can you post the output of

                          ls -lh /dev/tty*
                          

                          ?
                          If there is such a group than just add your user to it (see /etc/group). Then there is no need for chmod.

                          I added myself to 'dialout' and it actually works :D I will do the same on my work PC as well. I added the chmod to .basrc so every time I open up the terminal I must enter my passwd or Ctrl C out it :D

                          As for the other part, I suppose I have to use a log file. I mean I still get to scp it to my work PC and acces it on the panel PC as well. And his has as bonus effect that the 'history' is longer than the CLI's :D

                          Gents, I call this day a win!

                          A Offline
                          A Offline
                          artwaw
                          wrote on 12 Jul 2017, 11:55 last edited by
                          #11

                          @bask185 I am happy you got it working the way you wished for! Good luck!

                          For more information please re-read.

                          Kind Regards,
                          Artur

                          1 Reply Last reply
                          1

                          4/11

                          12 Jul 2017, 07:46

                          topic:navigator.unread, 7
                          • Login

                          • Login or register to search.
                          4 out of 11
                          • First post
                            4/11
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • Users
                          • Groups
                          • Search
                          • Get Qt Extensions
                          • Unsolved