2

Using Lubuntu 16.04 LTS. The terminal program is lxterminal. In Ubuntu with gnome-terminal I can specify size and location like:

gnome-terminal --geometry=80x30+100+100

However in Lubuntu running

lxterminal --geometry=80x30+100+100

Does not position the terminal where expected. Furthermore, repeated calls to the above command result in the window being positioned in different places. The lxterminal man page does not actually show position arguments

How do I specify a window position with lxterminal?

3

You can specify a window's position by editing $HOME/.config/openbox/lubuntu-rc.xml.

Back-up lubuntu-rc.xml as a safety measure.

Open $HOME/.config/openbox/lubuntu-rc.xml with a plain text editor.

Scroll down to the section titled <applications>. You'll see a lot of text commented out.

Immediately after the last commented line, paste the following:

  <application class="Lxterminal" name="lxterminal">
  <position force="yes">
    <x>-0</x>
    <y>0</y>
  </position>
  </application>

Save lubuntu-rc.xml (as a plain text file).

Open a terminal and run openbox --reconfigure. There should be no error dialog window indicating parsing errors, etc.

Now, when you run lxterminal, it should open at the top right corner of your screen. Once you're sure, lxterminal opens as specified in the example, edit lubuntu-rc.xml to adjust the x and y values to suit your needs remembering to run openbox --reconfigure to make the changes register after saving your edits.

You can consult http://openbox.org/wiki/Help:Applications for more details.

  • Is there a way to specify the position of a single window? I don't want every terminal window to open in the same spot, just the single terminal that I want opened on login. – User Feb 5 '18 at 4:37
  • Sorry, I don't know of a way to achieve that. – DK Bose Feb 5 '18 at 6:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.