Announcement

Collapse
No announcement yet.

[SOLVED] Automatic xrandr command

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [SOLVED] Automatic xrandr command

    I want to run an xrandr command automatically as soon as I log on. I tried putting it in rc.local, but I think that's too soon in the boot sequence. Anyone have a suggestion for which file I should put the command in? Thanks.

    #2
    Re: Automatic xrandr command

    Originally posted by Don
    I want to run an xrandr command automatically as soon as I log on. I tried putting it in rc.local, but I think that's too soon in the boot sequence. Anyone have a suggestion for which file I should put the command in? Thanks.
    Create a .desktop file containing the command and place it in ~/.config/autostart.
    Don't blame me for being smarter than you, that's your parent's fault.

    Comment


      #3
      Re: Automatic xrandr command

      Thanks for the suggestion. I gave that a try, creating "PortraitMode.desktop" with the command "xrandr -o left" and making it executable, but it did not run on boot-up. I have no doubt that I've screwed up something simple, but I'm sufficiently simple (always) and new (temporary, I hope) to Kubuntu that I don't know what it is.

      Comment


        #4
        Re: Automatic xrandr command

        from this

        try putting the commands here:
        /etc/kde4/kdm/Xsetup

        Comment


          #5
          Re: Automatic xrandr command

          Originally posted by Don
          Thanks for the suggestion. I gave that a try, creating "PortraitMode.desktop" with the command "xrandr -o left" and making it executable, but it did not run on boot-up. I have no doubt that I've screwed up something simple, but I'm sufficiently simple (always) and new (temporary, I hope) to Kubuntu that I don't know what it is.

          The format of the file is:

          Code:
          [Desktop Entry]
          Type=Application
          Exec=xrandr -o left
          Hidden=false
          X-GNOME-Autostart-enabled=true
          Name=PortraitMode
          Comment=
          Don't blame me for being smarter than you, that's your parent's fault.

          Comment


            #6
            Re: Automatic xrandr command

            Originally posted by claydoh
            from this

            try putting the commands here:
            /etc/kde4/kdm/Xsetup
            Why mess with system files when it's much simpler to use autostart?
            Don't blame me for being smarter than you, that's your parent's fault.

            Comment


              #7
              Re: Automatic xrandr command

              Thanks for staying on this, and thanks especially for the coding. Before I try this, I note that in the fifth line of code you have "X-GNOME." I'm using the KDE desktop. Should I substitute "KDE" for "GNOME"?

              Comment


                #8
                Re: Automatic xrandr command

                Originally posted by Don
                Thanks for staying on this, and thanks especially for the coding. Before I try this, I note that in the fifth line of code you have "X-GNOME." I'm using the KDE desktop. Should I substitute "KDE" for "GNOME"?
                Sorry, yes substitute KDE. I pasted it from a GNOME box not KDE.

                This may work better for you.

                Code:
                X-KDE-autostart-after=panel
                See this link to tweak to suit: http://l10n.kde.org/docs/admin/autos...d-runonce.html
                Don't blame me for being smarter than you, that's your parent's fault.

                Comment


                  #9
                  Re: Automatic xrandr command

                  Originally posted by zlow
                  Originally posted by claydoh
                  from this

                  try putting the commands here:
                  /etc/kde4/kdm/Xsetup
                  Why mess with system files when it's much simpler to use autostart?
                  It does its changes for all users, as well as doing its thing during the login process, not after (less visible resizing after the desktop loads). You of course can choose whatever works for you

                  Comment


                    #10
                    Re: Automatic xrandr command

                    Originally posted by claydoh
                    Originally posted by zlow
                    Originally posted by claydoh
                    from this

                    try putting the commands here:
                    /etc/kde4/kdm/Xsetup
                    Why mess with system files when it's much simpler to use autostart?
                    It does its changes for all users, as well as doing its thing during the login process, not after (less visible resizing after the desktop loads). You of course can choose whatever works for you
                    Fair enough.
                    Don't blame me for being smarter than you, that's your parent's fault.

                    Comment


                      #11
                      Re: Automatic xrandr command

                      Eureka! Except, instead of translating to "I have found it," it should be "you have found it." (My Greek's no better than my Kubuntu. My thanks to Zlow and Claydoh for the teaching.

                      Comment

                      Working...
                      X