## page was renamed from lubuntu-LXDE/Windows ## page was renamed from Lubuntu/Windows #this page should include documentation for openbox, window theming, how-tos on moving windows stuff like that #also lxpanel, since we don't have an lxpanel page <> {{{#!wiki warning {X} This wiki should be considered '''unmaintained''' and '''deprecated''', though some information may still be relevant. Please instead refer to [[ https://lubuntu.me | Lubuntu.me ]]. }}} ||<>|| = Small Screen, Big Windows = Press and hold Alt key and drag windows with mouse if they are too large for your screen. = Bottom Taskbar = == Changing Font Size == Right click on empty spot on the bottom panel, select "Panel Settings" <
> On "Geometry" Tab, increase Icon size to 36 pixels. == How to make/add an application to the "start" menu. == Here is a small example, it begins with editing a .desktop file, which you can copy to '''~/Desktop''' if you want to have it on your desktop like in Windows. {{{ gksudo leafpad /usr/share/applications/urxvt.desktop }}} {{{ [Desktop Entry] Name=URxvt Comment=Opens a terminal with UTF-8 and 256 colors support Encoding=UTF-8 Exec=urxvt Icon=gksu-root-terminal StartupNotify=true Terminal=false X-MultipleArgs=false Type=Application Categories=Application;System; NoDisplay=true }}} Another example: {{{ [Desktop Entry] Type=Application Icon= Name= Comment= Categories= Exec= Path= StartupNotify=true Terminal=false }}} Categories determine where this program will be placed in the menu. I suggest to check and inspect '''other .desktop files''' under '''/usr/share/applications/''' to give you more hint about this. Making a `.desktop` file in `~/.local/share/applications` will show the item in the LXDE start menu. More about this can be found from [[http://standards.freedesktop.org/desktop-entry-spec/latest/]] ----- == How do I assign certain program to open to a desktop #2 == In this example I'm going to show how to open Chromium browser in desktop #2, as I have it configured. Run in LXTerminal: {{{ leafpad ~/.config/openbox/lubuntu-rc.xml }}} Then you have to scroll all the way to the end of the file and locate the tag. On new lines between it and the tag, add: {{{ 2 }}} Now run: {{{ openbox --reconfigure }}} and you can start Chromium on any desktop, and it will be opened in desktop 2. Note it will not switch desktops. ------ == Changing running applications in panel to icons only == * right click panel * click '''Panel Preferences''' * click '''Panel Applets''' tab * click '''Task Bar (Window List)''' * click '''Edit''' button * check '''Icons only''' ------ == How can I create a shortcut on the Desktop == Launch LXTerminal and move to your Desktop directory {{{ cd ~home/Desktop lxshortcut -o application_name.desktop }}} (Of course you will want to change "application_name" to the name of the application you want adding). ------ == How to control window opacity == If you'd prefer to actually see through to your background windows, you need a compositing manager. [[http://www.compiz.org/|Compiz]] and [[http://cairo-compmgr.tuxfamily.org/|Cairo]] are two rather heavyweight solutions with lots of resource-heavy eyecandy. An alternative consistent with the small footprint of Lubuntu is `xcompmgr`. We will need to install this as well as `transset` to control the degree of opacity: {{{ sudo apt-get install xcompmgr transset }}} To get `xcompmgr` running every time: {{{ leafpad ~/.config/lxsession/Lubuntu/autostart }}} and add the line: {{{ @xcompmgr -c }}} which turns on translucency and soft shadows. Fading can be added with `-fD A` where `A` is milliseconds between steps in a fade. To control the level of opacity, make sure the program you want to change is running, then use: {{{ transset B }}} where `B` is some number between 0 and 1 where 0 is completely transparent and 1 is completely opaque. Then click on the window you want to change the transparency on. If you like fading, you may want to add `-F` to `xcompmgr` to allow for faded transitions when changing opacity. ----- == Change Color Of Taskbar or LxPanel == Need a your taskbar to be a different color? * Right click on the panel, (but not an application) and select "Panel Settings" * Select the "Appearance" top-tab. * You have several options to change the panel color. ----- == Turn off iconify/minimize window animation in 12.04 == * Open the Terminal * Type: `leafpad ~/.config/openbox/lubuntu-rc.xml` * Look for `yes` * Change it to `no` * Save the file * Type: `openbox --reconfigure` ----- == Restart lxpanel == #perhaps move to lxpanel page? {{{ lxpanelctl restart or killall lxpanel && lxpanel --profile Lubuntu }}} ----- = Disable accidental desktop switching = see [[Lubuntu/Mouse#Disable_how_using_the_scrollwheel_on_the_switches_to_the_next_Desktop]] ----- = Launching Windows Maximized or Fullscreen = Some programs remember the size they were when you closed them and then reopen with that size. But suppose you always want to open a certain program maximized irrespective of the size it was the last time you used it. Then, there maybe some applications you want to always open fullscreen (as opposed to maximized). Lubuntu users can do so by editing `~/.config/openbox/lubuntu-rc.xml`. A little bit about `lubuntu-rc.xml` first. This file contains several sections: resistance, focus, placement, theme, desktops, resize, margins, dock, keyboard, mouse, menu, and applications. For our purpose, we'll be interested in the last section, `applications`. But before anything else, '''''please make a backup of this file just in case'''''. To backup via the command line you could use `cp ~/.config/openbox/lubuntu-rc.xml ~/.config/openbox/lubuntu-rc.backup` or you could use the file manager. A small note ... when editing XML (or other files containing code), it's preferable to use a text editor that highlights code syntax. `Leafpad` doesn't. `Nano`, which runs in a terminal does. If you prefer the GUI route, `medit` is nice and can be installed from the software center. Assuming you use `nano`, just type `nano ~/.config/openbox/lubuntu-rc.xml` and hit `enter`. Now that you've opened `lubuntu-rc.xml`, you'll see that the entire '''''applications''''' section is commented out. Commenting out stuff in `.xml` files is done by enclosing the stuff within '''''''''' at the end. Now that you know that, you are in a position to `uncomment` the following subsection: {{{ }}} to look like this: {{{ true }}} Save `lubuntu-rc.xml` and exit the text editor. Then, in a terminal, type `openbox --reconfigure` and press `Enter`. (This step is necessary to let Openbox know that you've altered one of its files and it also catches certain mistakes and lets you know in the terminal window.) At this point, any program you open will probably open maximized. Why "probably"? That's because of the use of `normal` in ``. The idea here is to restrict the `maximize` effect to the "main" window and not to have things like dialog windows or panels open maximized as well. If you want everything to open maximized, you'd use something like ``. But what if you want only some programs to open maximized and not others? That can be done too. Here's a bit of code that will make most browsers open maximized (assuming you haven't uncommented out the section to `Maximize all normal windows`). {{{ yes }}} Notice that now we've used ``. Why? Because by specifying `application role="browser"` we can have Chrome/Chromium, Firefox, Opera and Seamonkey all open maximized. There's another reason and that has to do with each browser's "internal" dialog boxes, panels, and windows. So the use of `application role="browser"` ensures that internal stuff such as Firefox' Preferences pane (`Alt+Edit+Preferences`) or Chrome's Task Manager (`Shift+Escape`) don't open maximized as well. But suppose you just want the one browser to always open maximized? You need to get a little more information first. The procedure requires having '''both''' your terminal and your desired browser window open side by side. Now type the code given below and press `Enter`: {{{ xprop | grep "^_OB_APP" }}} The cursor in the terminal changes to cross-hairs. Using the mouse, move the cursor over to the browser's window and single-click in there. You'll then see the following output in your terminal (if Google Chrome is the browser open): {{{ _OB_APP_TYPE(UTF8_STRING) = "normal" _OB_APP_TITLE(UTF8_STRING) = "Untitled - Google Chrome" _OB_APP_CLASS(UTF8_STRING) = "Google-chrome" _OB_APP_NAME(UTF8_STRING) = "google-chrome" _OB_APP_ROLE(UTF8_STRING) = "browser" }}} With that information, we can now add the following subsection to the `Applications` section in `lubuntu-rc.xml`: {{{ yes }}} Note that that if you run the `xprop` command and click on Chrome's Task Manager, you'll see: {{{ _OB_APP_TYPE(UTF8_STRING) = "normal" _OB_APP_TITLE(UTF8_STRING) = "Task Manager - Google Chrome" _OB_APP_CLASS(UTF8_STRING) = "Google-chrome" _OB_APP_NAME(UTF8_STRING) = "google-chrome" _OB_APP_ROLE(UTF8_STRING) = }}} And just in case you think that application names are obvious or "intuitive", here's what you see for LibreOffice Calc (if you have it handy) {{{ _OB_APP_TYPE(UTF8_STRING) = "normal" _OB_APP_TITLE(UTF8_STRING) = "Untitled 1 - LibreOffice Calc" _OB_APP_CLASS(UTF8_STRING) = "libreoffice-calc" _OB_APP_NAME(UTF8_STRING) = "VCLSalFrame.DocumentWindow" _OB_APP_ROLE(UTF8_STRING) = }}} and for its Options window: {{{ _OB_APP_TYPE(UTF8_STRING) = "dialog" _OB_APP_TITLE(UTF8_STRING) = "Options - LibreOffice - User Data" _OB_APP_CLASS(UTF8_STRING) = "Soffice" _OB_APP_NAME(UTF8_STRING) = "soffice" _OB_APP_ROLE(UTF8_STRING) = }}} Now that you've read all that, launching applications fullscreen is easy. Use something like this (changing `whatever` to the relevant name): {{{ yes }}} If you don't like to edit `lubuntu-rc.xml` directly, there '''is''' a GUI-based approach. It requires installing a program called '''OBApps''' and its dependencies. Now, OBApps, unfortunately, isn't in the repos and so its installation is just a little lengthy. * Download it from here: https://sourceforge.net/projects/obapps/files/obapps-0.1.7.tar.gz/download * Extract the contents using Archive Manager (for example) * Read the README to find out what the current additional requirements are. For now, with version 0.1.7, users may need to install python-xlib, python-wxgtk2.8, python-wxtools, and wx2.8-il8n. All of these can be installed by `sudo apt-get install` * Open a terminal, change directory to where you've extracted the tar file, and run the install command which currently is ` sudo python setup.py install`. OBApps should now be installed and available by pressing `Alt`+`F2`, entering `obapps` in the text area, and pressing `Enter`. If you wish to have OBApps appear in Lubuntu's menu so that you can launch it from there, we need to make a `.desktop` file. Here's one: {{{ [Desktop Entry] Version=1.0 Name=OBApps Comment=GUI for per-app window settings; version 0.1.7 Exec=/usr/local/bin/obapps Icon=/usr/share/icons/gnome/32x32/apps/preferences-desktop-theme.png Terminal=false Type=Application Categories=Settings;DesktopSettings;GTK; }}} You can save the contents as `obapps.desktop` in `/usr/share/applications` (for all users) or in `~/.local/share/applications` for a specific user. Also, the choice of an icon is up to you. As the README suggests, make a back up of `lubuntu-rc.xml` before using OBApps! ----- = Reposition and Resize Windows Without Using a Mouse = `Note: If you're using 13.04 or later, something very similar to the code described below is present, by default, in lubuntu-rc.xml. See the section titled "Keybindings for window tiling".` `So, all users of Lubuntu 13.04 or later, may need to do is to tweak the values and keybinding to suit individual needs.` Want to make an existing active window occupy the top, bottom, left, or right half of your screen? Very simple! This sort of "aerosnap" is available by default and without having to install extra software or resorting to compositing managers. And it's possible to do so precisely and by pressing just a couple of keys. This is done by editing `~/.config/openbox/lubuntu-rc.xml` after making a backup for safety. (If you don't know what `lubuntu-rc.xml` is, [[http://pclosmag.com/html/Issues/201107/page08.html|Openbox - Edit rc.xml to Gain Control]] is a very well-written article on the subject.) At the outset, I'll point out the most difficult aspect of "aerosnap": it's the choice you make for assigning which keys do what. You need to ensure that you (or the programs you use) don't already use the same key combinations! You won't get any warning; things may just not work the way you intend! Okay, now that you've opened `lubuntu-rc.xml`, search for a line that has just ``. Then, just above that line, (carefully) paste in any or all of the code samples given below after reading the notes: * The key combinations below '''work for me''' on '''my laptop''' because I'm sure that nothing else uses the combinations of pressing the `Super` (or `Windows`) key denoted by `W` and the up, down, left or right arrow keys (not those on the number pad!). * If you want to use some other keys then `C`, `S`, and `A` denote the control, shift, and alt keys, respectively. * For example, if you want to assign pressing `control` + `shift` + `Z` together to some action, you'd use `C-S-Z`. * The sizes used, when not in percentages, are in screen pixels; my laptop has a height of 768 px and I have my panel on the top: {{{ 0 0 97% 49% }}} {{{ -0 0 97% 49% }}} {{{ 0 -50% 100% 350 }}} {{{ -0 -0 100% 340 }}} {{{ center center }}} Save the file, exit the editor, open a terminal and run `openbox --reconfigure`. As soon as you've done so, you can press the key combinations you've chosen to see the effect on the window that currently has focus. The examples given here are the simplest. There are many more tricks. [[http://openbox.org/wiki | This page]] will get you started. Also, you can look at [[https://bbs.archlinux.org/viewtopic.php?id=93126 | Openbox Hacks and Configs Thread]].