Kirjoittaja Aihe: Openbox opas  (Luettu 73335 kertaa)

Zhraelyn

  • Vieras
Openbox opas
« : 05.05.07 - klo:19.43 »
OPENBOX TUTORIAALI

Aluksi tahdon kiittää raimoa, joka neuvoi minua alunperin openboxin käytössä. Ilman häntä olisin luultavasti kyllästynyt jo alussa. Paljon sitä silloin taisteltiin ja raimo korjaili vesipumppua joka oli poksahtanut ja taisipa tuo käydä omaa taisteluaan jotain kottikärryn rengasta vastaan. Kiitos kärsivällisyydestä.


Openbox on hyvin kevyt ikkunointiohjelma, X-ikkunointia tukeville käyttöjärjestelmille. Jos et ole valmis työpöytään, jota säädellään päätteen kautta varsin paljon tekstieditorin avulla, tämä opas ei ole sinulle. Openbox ei ole sinulle "se oikea."

Openboxin asennus:

Se on helppoa, aukaise pääte (terminal) ja kirjoita/kopioi siihen tämä:

Koodia: [Valitse]
sudo apt-get install openbox openbox-themes obconf adesklets idesk rox-filer pypanel
Toimenpiteen jälkeen voit kirjautua ulos ja kirjautua Openboxin puolelle, istunnot kohdasta valitset Openboxin.

Nyt kun Openbox on asennettuna ja kaikki muut tarvittavat, joita tässä tutossa tarvitaan, katsotaan miten saat itsellesi taustakuvan:

Koodia: [Valitse]
cd
cp /usr/share/idesk/dot.ideskrc ~/.ideskrc
gedit .ideskrc
#Vaihdat nyt tulevan taustakuvan nimen Bacground.File riviin. Eli taustakuvan pitää olla samalla nimellä.
Background.File: ~/.idesktop/rain.jpg
cd ~/.idesktop
mkdir .idesktop

#Nyt haetaan haluamasi kuva, sen pitää olla TÄYSIN samalla nimellä tai se ei toimi. Nimenhän voi aina muokata.
wget http://www.linuxwallpapers.org/linux/rain.jpg
#käynnistä idesk ja taustakuva tulee näkyviin.
idesk &

adeskletit, asennetaan ne:

Koodia: [Valitse]
cd
mkdir adesklets
cd adesklets
wget http://switch.dl.sourceforge.net/sourceforge/adesklets/weather-0.0.4.tar.bz2
wget http://switch.dl.sourceforge.net/sourceforge/adesklets/modubar-0.0.1.tar.bz2
#puretaan ladatut tavarat, ole edelleen samassa hakemistossa.
tar -xvvf weather-0.0.4.tar.bz2
tar -xvvf modubar-0.0.1.tar.bz2

#Asetuksia pitäisi vielä säätää, mutta rekataan eka adskletit:
cd weather-0.0.4
#Nyt sinun pitäisi olla ~/adesklets/weather-0.0.4 hakemistossa.
./weather.py
#Paina r, mitään erikoista ei vielä tapahdu.

cd adesklets
cd modubar-0.0.1
#Nyt sinun pitäisi olla ~/adesklets/modubar-0.0.1 hakemistossa.
./modubar.py
#Nyt taas rekataan, r ja entteriä.

Varmista että sinun ~/.adesklets tiedosto näyttää kutakuinkin samalta kuin minulla on (editorisi ~/.adesklets )
Lainaus
# This is adesklets configuration file.
#
# It gets automatically updated every time a desklet main window
# parameter is changed, so avoid manual modification whenever
# a desklet is running. In fact, manual changes to this file
# should rarely be needed. See `info adesklets'.

[/home/jani/adesklets/weather-0.0.4/weather.py]
id=0 screen=0 x=0 y=0

[/home/jani/adesklets/modubar-0.0.1/modubar.py]
id=0 screen=0 x=0 y=0

(MUISTA VAIHTAA POLUT OIKEAKSI!! Eli janin tilalle sinun tunnuksesi )

Modubarin kuvakkeiden käynnistyskäskyt voi säätää mieleisekseen: ~/adesklets/modubar-0.0.1/icons -- Tänne halutut kuvakkeet.
~/adesklets/modubar-0.0.1/config.txt  -- Tähän tiedostoon säädöt. Käyntiin lähtee Openboxin puolella näin: adesklets. Pypanel käynnistyy kirjoittamalla päätteeseen pypanel. Se paneli tulikin nyt alareunaan, joten päätteessä ctrl+c yhdistelmällä sulje se. Se piti käynnistää vain sen takia, että asetustiedosto syntyi. Muokkaa:
Koodia: [Valitse]
tekstieditorisi ~/.pypanelrc etsi sieltä P_LOCATION ja muuta siihen 0. Nyt paneeli tulee ylös.

idesk ikonit: Ikoneiden periaate on se, että jokaisella ikonilla on oma *.Ink tiedostonsa sekä tietenkin kuvansa ~/.idesktop hakemistossa. Esimerkkiä:

Lainaus
table Icon
  Caption: Ubuntulandia
  Command: firefox http://ubuntu.com/
  Icon: /usr/share/pixmaps/firefox.png
  Width: 48
  Height: 48
  X: 33
  Y: 68
end



Tässä minun ~/.ideskrc ja ~/.pypanelrc josta voi ottaa mallia, oikeastaan tämä on ihan raimon tekemä alunperin, mutta otin tämän toisen koneen (raato) johon silloin kesällä openboxin pistin. Myöhemmin voin lisätä ihan kokonaan itse väkertämän.

Tätä kun tutkailee pystyy huomaamaan, että fonttia on säädetty paremmaksi ja vihreäksi sekä taustakuvan mode on scale. Tätä käyttämällä pääset helpoimmalla.

Lainaus
table Config
  FontName: VeraBd
  FontSize: 14
  FontColor: #60C060
  ToolTip.FontSize: 14
  ToolTip.FontName: VeraBd
  ToolTip.ForeColor: #000000
  ToolTip.BackColor: #FFFFFF
  ToolTip.CaptionOnHover: false
  ToolTip.CaptionPlacement: Right
  Locked: false
  Transparency: 60
  Shadow: false
  ShadowColor: #000000
  ShadowX: 1
  ShadowY: 1
  Bold: true
  ClickDelay: 300
  IconSnap: true
  SnapWidth: 10
  SnapHeight: 10
  SnapOrigin: BottomRight
  SnapShadow: false
  SnapShadowTrans: 200
  CaptionOnHover: false
  CaptionPlacement: bottom
  FillStyle: none
  Background.Delay: 0
  Background.Source: None
  Background.File: ~/.idesktop/rain.jpg
  Background.Mode: Scale
  Background.Color: #CCDCCC
end

table Actions
  Lock: control right doubleClk
  Reload: middle doubleClk
  Drag: left hold
  EndDrag: left singleClk
  Execute[0]: left doubleClk
  Execute[1]: right doubleClk
end

~/.pypanelrc :

Sitä on muokattu jo enemmän, fontit on nimittäin isonnettu ja värejä on säädetty jne. Tiedostossa ei saa olla ääkkösiä, edes kommenteissa joten muistakaapa se!

Lainaus
#------------------------------------------------------------------------------
#
#                         PyPanel v2.4 Configuration
#
# This configuration file is a Python script that will be executed when
# PyPanel is started.  In order for PyPanel to start properly, make sure that
# this file contains proper Python formatting and no syntax errors.
#------------------------------------------------------------------------------
VERSION         = 2.4           # Config file version

#------------------------------------------------------------------------------
# Colors: Format is hex triplet - 0xrrggbb
#------------------------------------------------------------------------------
BG_COLOR        = "0xc6f6c6"    # Panel background and tinting color
TASK_COLOR      = "0x80B080"    # Normal task name color
FOCUSED_COLOR   = "0x80C080"    # Focused task name color
SHADED_COLOR    = "0x808080"    # Shaded task name color
MINIMIZED_COLOR = "0x808080"    # Minimized task name color
DESKTOP_COLOR   = "0x80B080"    # Desktop name color
CLOCK_COLOR     = "0x80B080"    # Clock text color
LINE_COLOR      = "0x606060"    # Vertical line color

# Text Shadow Colors
TASK_SHADOW_COLOR      = "0xffffff"
FOCUSED_SHADOW_COLOR   = "0xffffff"
SHADED_SHADOW_COLOR    = "0xffffff"
MINIMIZED_SHADOW_COLOR = "0xffffff"
DESKTOP_SHADOW_COLOR   = "0xffffff"
CLOCK_SHADOW_COLOR     = "0xffffff"

#------------------------------------------------------------------------------
# Panel Spacing and Location Options: Measured in pixels
#------------------------------------------------------------------------------
P_LOCATION      = 0             # Panel placement: 0 = top, 1 = bottom
P_WIDTH         = 0             # Panel width: 0 = Use full screen width
P_START         = 0             # Starting X coordinate of the panel
P_SPACER        = 6             # Spacing between panel objects
P_HEIGHT        = 24            # Panel height

#------------------------------------------------------------------------------
# Icon Size Options: Measured in pixels
#------------------------------------------------------------------------------
I_HEIGHT        = 16            # Panel application icon height
I_WIDTH         = 16            # Panel application icon Width
APPL_I_HEIGHT   = 24            # Application launcher icon height
APPL_I_WIDTH    = 24            # Application launcher icon width
TRAY_I_HEIGHT   = 24            # System tray icon height (usually 16 or 24)
TRAY_I_WIDTH    = 24            # System tray icon width  (usually 16 or 24)
                                # If TRAY_I_WIDTH is set to 0, then the
                                # width specified by the tray app will be used
                               
#------------------------------------------------------------------------------
# Panel Clock Format: 'man strftime' for detailed formatting options and help
#------------------------------------------------------------------------------
CLOCK_FORMAT    = "%d.%m.%Y"    # Ex: 2004-09-25 17:45 now %d.%m.%Y = 21.07.2006

#------------------------------------------------------------------------------
# Clock Delay: Seconds between each clock update during periods of inactivity
#------------------------------------------------------------------------------
CLOCK_DELAY     = 20

#------------------------------------------------------------------------------
# Hidden Application List: Apps listed here will not be display on the panel
# The application name is its WM_CLASS name, use 'xprop' to find WM_CLASS
# Ex: ["xmms", "xine", "gDesklets"]
#------------------------------------------------------------------------------
HIDE_LIST       = []           
                   
#------------------------------------------------------------------------------
# Hidden Panel Size: Size of the panel when it's hidden/minimized
#------------------------------------------------------------------------------
HIDDEN_SIZE     = 2

#------------------------------------------------------------------------------
# Panel Text Font: This option takes either a traditional or Xft font string
# Ex: "-schumacher-clean-medium-r-normal-*-12-*-*-*-*-*-*-*"
#     "aquafont-8"
#------------------------------------------------------------------------------
FONT            = "bitstream vera sans-13"

#------------------------------------------------------------------------------
# Show All Applications: Show apps from all desktops or just the current
# 0: Disabled - Only applications on the current desktop will be displayed
# 1: Enabled  - Selected apps are moved to the current desktop
# 2: Enabled  - Current desktop is changed to the selected apps desktop
#------------------------------------------------------------------------------
SHOWALL         = 0             # 0, 1 or 2 - see descriptions above

#------------------------------------------------------------------------------
# Show Minimized/Iconified Applications: Show only minimized apps or all apps
# 0: Disabled - Show all applications on the panel
# 1: Enabled  - Show only minimized apps on the panel
#------------------------------------------------------------------------------
SHOWMINIMIZED   = 0

#------------------------------------------------------------------------------
# Application Icon List: List of custom icons for specific applications
# The application name is its WM_CLASS name, use 'xprop' to find WM_CLASS
#
# The "default" entry is used for applications with no icon.  If left "",
# PyPanel will use the default icon distributed with the source.
#
# Add entries using the following format -
#     "<application name>" : "<full path to icon>",
#------------------------------------------------------------------------------
ICON_LIST       = {
                   "default" : "",
                   "example" : "/usr/share/data/images/audio.png",
                  }
                 
#------------------------------------------------------------------------------
# Application Launch List: Ordered list of icons and applications for the
#                          application launcher.
#
# Add entries using the following format -
#     ("<executable>", "<full path to icon>")
#------------------------------------------------------------------------------
# katso /usr/share/pixmaps siella on kuvakkeita mm.
#/usr/share/pixmaps/gnome-terminal.png
# ("komento", "kuvake"),
# ("komento2", "kuvake2"),

LAUNCH_LIST     = [
                   ("epiphany", "/home/TUNNUS/.idesktop/firefox_green.png"),
                   ("gnome-terminal", "/home/TUNNUS/.idesktop/terminal_green.png"),
                   ("leafpad ~/.readme", "/home/TUNNUS/.idesktop/doc_green.png"),
                  ]

#------------------------------------------------------------------------------
# Background Alpha/Shade Level: 0 (Fully Translucent) -> 255 (Fully Opaque)
# BG_COLOR is used for tinting
#------------------------------------------------------------------------------
SHADE           = 35

#------------------------------------------------------------------------------
# Misc. Options: 1 = Enabled/Yes, 0 = Disabled/No
#------------------------------------------------------------------------------
ABOVE           = 1             # Panel is always above other apps #On theTop
APPICONS        = 1             # Show application icons
AUTOHIDE        = 0             # Autohide uses the CLOCK_DELAY timer above
SHADOWS         = 0             # Show text shadows
SHOWLINES       = 0             # Show object seperation lines
SHOWBORDER      = 0             # Show a border around the panel

#------------------------------------------------------------------------------
# Desktop Names: Configure the names of your desktops
# If the option is [], PyPanel will attempt to use the desktop name specified
# by the XServer, if that fails it will use the desktop number as its name
# Ex. ["One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight"]
#------------------------------------------------------------------------------
DESKTOP_NAMES   = []

#------------------------------------------------------------------------------
# Panel Layout:       -----------------------------------
#                     [  1  ][  2  ][  3  ][  4  ][  5  ]
#                     -----------------------------------
#
# The panel layout is split into 5 sections numbered 1, 2, 3, 4 or 5 as shown
# in the diagram above.  Each of the following objects can be enabled by
# assigning it a section number or disabled by assigning it 0:
#------------------------------------------------------------------------------
DESKTOP         = 4             # Desktop name section
TASKS           = 2             # Task names section
TRAY            = 3             # System tray section
CLOCK           = 5             # Clock section
LAUNCHER        = 1             # Application launcher section

#------------------------------------------------------------------------------
#                       Button Event Function Definitions
#------------------------------------------------------------------------------
# Left click   - button 1
# Middle click - button 2
# Right click  - button 3
# Wheel up     - button 4
# Wheel down   - button 5
#
# changeDesktop(x)
# - Change Desktop: Increase or decrease the current desktop by 'x' amount
#
# toggleShade(task)
# - Shade or Unshade an application
#
# toggleHidden()
# - Minimize the panel to the top or bottom depending on its start location
#
# toggleMinimize(task, traise=1)
# - Minimize or Unminimize an application and optionally raise it
#
# taskRaise(task, focus=1)
# - Raise an application to the top of the window list and optionally focus it
#
# taskLower(task, focus=0)
# - Lower an app to the bottom of the window list and optionally focus it
#
# taskFocus(task)
# - Give focus to the selected application, if it has focus then minimize it
#
# showDesktop()
# - Toggle between hiding and unhiding ALL applications
#------------------------------------------------------------------------------

#----------------------------------
def desktopButtonEvent(pp, button):
#----------------------------------
    """ Button event handler for the panel's desktop object """
       
    if button == 1:
        pp.changeDesktop(-1)
    elif button == 2:
        pp.changeDesktop(2)
    elif button == 3:
        pp.changeDesktop(1)
    elif button == 4:
        pp.changeDesktop(1)
    elif button == 5:
        pp.changeDesktop(-1)
       
#--------------------------------
def clockButtonEvent(pp, button):
#--------------------------------
    """ Button event handler for the panel's clock object """
   
    if button == 1:
        os.system("xclock &")
    elif button == 2:
        pp.showDesktop()
    elif button == 3:
#        pp.toggleHidden()
        pp.showDesktop() 
    elif button == 4:
        pp.showDesktop()
    elif button == 5:
        pp.showDesktop()
       
#--------------------------------
def panelButtonEvent(pp, button):
#--------------------------------
    """ Button event handler for the panel with no active tasks """
   
    if button == 1:
        pass
    elif button == 2:
        pass
    elif button == 3:
        pass
    elif button == 4:
        pass
    elif button == 5:
        pass
       
#-------------------------------------
def taskButtonEvent(pp, button, task):
#-------------------------------------
    """ Button event handler for the panel's tasks """
   
    if button == 1:
        pp.taskFocus(task)
    elif button == 2:
        # Destroy the application
        task.obj.destroy()
    elif button == 3:
        # Ex. - XMMS doesn't shade, so we want to minimize it instead and
        #       still use button 3 to shade other applications
        #       task.tclass is the tasks class name (WM_CLASS)
        if "xmms" in task.tclass:
            pp.toggleMinimize(task)
        else:
            pp.toggleShade(task)
    elif button == 4:
        pp.taskRaise(task, focus=1)
    elif button == 5:
        pp.taskLower(task, focus=0)
       

Tämän jälkeen työpöytäsi pitäisi näyttää suunnilleen tältä:


(Klikkaa kuvaa, se aukeaa uuteen ikkunaan ja suurenee)

Otan mielelläni palautetta vastaan, tulen lisäämään tähän vielä asioita, tässä nyt jonkinlainen alku. Kehittävää palautetta odotellen;

- Jan1

« Viimeksi muokattu: 05.05.07 - klo:20.59 kirjoittanut Jan1 »

mikkohuo

  • Käyttäjä
  • Viestejä: 562
  • The Ubuntu Counter Project - user number #3339
    • Profiili
Vs: Openbox opas
« Vastaus #1 : 06.05.07 - klo:13.26 »
Ohje ja lopputulos ovat mainoita! Eikös tämän olisi kuitenkin voinut tehdä tuonne wikin puolelle?

http://www.ubuntu-fi.org/Wiki/Wiki


Risto H. Kurppa

  • Käyttäjä
  • Viestejä: 3024
  • Useita Kubuntuja ajossa.
    • Profiili
    • http://risto.kurppa.fi
Vs: Openbox opas
« Vastaus #2 : 06.05.07 - klo:13.42 »
Whoa, respect!


Mutta pistä tosiaan tuonne wikiin, ohjeet keskitetään nykyään sinne ja täällä niistä voidaan jutskailla. Wikissä ne on helpommin jatkokäytettävissä ja kehitettävissä ja paremmin myös näkyvissä (varsinkin kun sivustoa uudistetaan)


r
UUSI UBUNTUN KÄYTTÄJÄ: SÄÄSTÄ AIKAASI LUKEMALLA  -> TÄMÄ <-

Zhraelyn

  • Vieras
Vs: Openbox opas
« Vastaus #3 : 17.05.07 - klo:20.00 »
Jos joku viitsii niin voi pistää tuonne Wikiin, luvan annan. Kun itse en ole pahemmin tuon Wikin kanssa leikkinyt ja nopeasti koittamalla jälki ei kovinkaan hienolta näyttänyt, vaan tästä tuli hyvinkin sekava. Kiitos jos joku wikiin tämän pistää.

Kalle Kipinä

  • Käyttäjä
  • Viestejä: 78
    • Profiili
Vs: Openbox opas
« Vastaus #4 : 18.05.07 - klo:02.15 »
Ja ideskin, adeskletsin ja pypanelin saa käynnistymään automaattisesti openboxin käynnistyessä niin haluttaessa. Alkuperäinen ohje löytyy Arch Linuxin wikistä, http://wiki.archlinux.org/index.php/Openbox#Running_programs_at_startup, itse muokkasin ubuntu-kokoonpanoon (käynnistin ei sijaitse Ubuntussa samassa hakemistossa kuin Archissa).

Muokataan Openboxin käynnistintä:
Koodia: [Valitse]
sudo nano /usr/share/xsessions/openbox.desktop

Kohta, jossa lukee Exec=XXX korvataan kahdella rivillä:
Koodia: [Valitse]
Exec=/usr/bin/openbox-startup
TryExec=/usr/bin/openbox-startup

Luodaan käynnistin /usr/bin/openbox-startup ja annetaan sille ajo-oikeudet:
Koodia: [Valitse]
sudo touch /usr/bin/openbox-startup
sudo chmod a+x /usr/bin/openbox-startup

Muokataan äsken luotua tiedostoa:
Koodia: [Valitse]
sudo nano /usr/bin/openbox-startup

Lisätään rivit:
#!/bin/sh
openbox &
$HOME/.config/openbox/startup
wait

Luodaan vielä oman kotihakemiston alle asetustiedosto ja annetaan sillekin ajo-oikeudet, tällä kertaa tosin vain itselle:
Koodia: [Valitse]
touch ~/.config/openbox/startup
chmod u+x ~/.config/openbox/startup

Ja muokataan tätä lopuksi halutulla tavalla. Esimerkiksi vain idesk, adesklets ja pypanel käynnistyvät näin:
Koodia: [Valitse]
nano ~/.config/openbox/startup

Lisätään rivit:
#!/bin/sh
adesklets &
idesk &
pypanel &

pjotr

  • Käyttäjä
  • Viestejä: 625
    • Profiili
Vs: Openbox opas
« Vastaus #5 : 18.05.07 - klo:08.05 »
Tämä opas alkaa olemaan aikas mainio! Lisäksi vielä tämä Riston ohje, jolla pypaneliin saa käynnistimiä:

http://forum.ubuntu-fi.org/index.php?topic=431.msg21522#msg21522

[offtopic]Kummalta tuntuu vaan taas käyttää vaihteeksi Openboxia kun on niin tottunut Gnomen työpöytäefekteihin... ikkunat ei huoju eikä kuutio pyöri...[/offtopic]

Edit: ainiin, vielä Openboxin menun muokkauksesta jotain:

Koodia: [Valitse]
cp /etc/xdg/openbox/menu.xml ~/.config/openbox
Koodia: [Valitse]
nano ~/.config/openbox/menu.xml
Lisää tiedostoon vaikkapa rivit:
Koodia: [Valitse]
<item label="Eterm">
   <action name="Execute"><execute>Eterm</execute></action>
</item>

<item label="Mozilla Firefox">
   <action name="Execute"><execute>firefox</execute></action>
</item>

Lainaus Kubuntulta.

Edit 2: Työn tulos




« Viimeksi muokattu: 18.05.07 - klo:12.47 kirjoittanut pjotr »
www.tehotuotanto.net

The surest sign that intelligent life exists elsewhere in the Universe is that none of it has tried to contact us.

Zhraelyn

  • Vieras
Vs: Openbox opas
« Vastaus #6 : 18.05.07 - klo:14.04 »
Niin alkaa, kun Wikiin saisi läntättyä niin kasvaisi kivasti tämä opas. Kun halukkaat pystyvät helposti muokkaamaan ja pistämään oman vinkkinsä/ohjeensa muiden nähtäville.

_Pete_

  • Käyttäjä
  • Viestejä: 1836
  • Fufufuuffuuu
    • Profiili
Vs: Openbox opas
« Vastaus #7 : 18.05.07 - klo:15.00 »

[offtopic]Kummalta tuntuu vaan taas käyttää vaihteeksi Openboxia kun on niin tottunut Gnomen työpöytäefekteihin... ikkunat ei huoju eikä kuutio pyöri...[/offtopic]


Tarkoitat varmaankin beryl/emerald efektejä ?


pjotr

  • Käyttäjä
  • Viestejä: 625
    • Profiili
Vs: Openbox opas
« Vastaus #8 : 18.05.07 - klo:15.25 »
Tarkoitat varmaankin beryl/emerald efektejä ?

Gnome Compiz Preferences lukee otsikkona siinä millä niitä voi säätää...

Edit:

Koodia: [Valitse]
sudo apt-get install gnome-compiz-manager
« Viimeksi muokattu: 18.05.07 - klo:15.45 kirjoittanut pjotr »
www.tehotuotanto.net

The surest sign that intelligent life exists elsewhere in the Universe is that none of it has tried to contact us.

eliasj

  • Käyttäjä
  • Viestejä: 4075
    • Profiili
Vs: Openbox opas
« Vastaus #9 : 19.05.07 - klo:13.52 »
Kyllä Openboxiinkin saa Berylin/Compizin. Tai siis ei Openboxiin. Koska Beryl/Compiz on oma ikkunamanageri. Et saa Beryliä/Compizia Metacityynkään. :P Minulla oli jokin aika sitten Beryl ja siinä päällä pypanel + idesk. Hyvältä näytti ja ikkunat huojuivat!
alias vililikku

pjotr

  • Käyttäjä
  • Viestejä: 625
    • Profiili
Vs: Openbox opas
« Vastaus #10 : 19.05.07 - klo:14.03 »
Kyllä Openboxiinkin saa Berylin/Compizin. Tai siis ei Openboxiin. Koska Beryl/Compiz on oma ikkunamanageri. Et saa Beryliä/Compizia Metacityynkään. :P Minulla oli jokin aika sitten Beryl ja siinä päällä pypanel + idesk. Hyvältä näytti ja ikkunat huojuivat!

Kerropa miten... Kun käynnistin Openboxista tuon GL Destopin niin X:n käynnistyi uudelleen ja päädyin gdm:ään. Tosin tuo Openbox on sen keveyden takia, kun pyörittää VirtualBoxissa XP:tä tai Win Server 2003:a niin ideana on se ettei kone tahmaa ainakaan sen takia koska käyttää resursseja ylimääräiseen silmäkarkkiin.

Tuosta voisi vielä ottaa tuon gdesklets pois...

Koodia: [Valitse]
GNU nano 2.0.2     File: /home/pjotr/.config/openbox/startup                 

#!/bin/sh
gdesklets &
feh --bg-center /home/pjotr/.taustoja/biteme.jpg &
pypanel &
firefox &
www.tehotuotanto.net

The surest sign that intelligent life exists elsewhere in the Universe is that none of it has tried to contact us.

eliasj

  • Käyttäjä
  • Viestejä: 4075
    • Profiili
Vs: Openbox opas
« Vastaus #11 : 19.05.07 - klo:14.21 »
Kyllä Openboxiinkin saa Berylin/Compizin. Tai siis ei Openboxiin. Koska Beryl/Compiz on oma ikkunamanageri. Et saa Beryliä/Compizia Metacityynkään. :P Minulla oli jokin aika sitten Beryl ja siinä päällä pypanel + idesk. Hyvältä näytti ja ikkunat huojuivat!

Kerropa miten... Kun käynnistin Openboxista tuon GL Destopin niin X:n käynnistyi uudelleen ja päädyin gdm:ään. Tosin tuo Openbox on sen keveyden takia, kun pyörittää VirtualBoxissa XP:tä tai Win Server 2003:a niin ideana on se ettei kone tahmaa ainakaan sen takia koska käyttää resursseja ylimääräiseen silmäkarkkiin.

Tuosta voisi vielä ottaa tuon gdesklets pois...

Koodia: [Valitse]
GNU nano 2.0.2     File: /home/pjotr/.config/openbox/startup                 

#!/bin/sh
gdesklets &
feh --bg-center /home/pjotr/.taustoja/biteme.jpg &
pypanel &
firefox &
Et voi käyttää Openboxista Beryliä, koska Beryl on oma ikkunamanagerinsa. Eli teet sille samanlaisen käynnistimen kuin Openboxille GDM:ään. Arch Linuxin ohje: http://wiki.archlinux.org/index.php/Beryl http://wiki.archlinux.org/index.php/Beryl#No_Desktop.2C_Beryl_as_window_manager_only Tuolta voit soveltaa Ubuntulle.
alias vililikku

pjotr

  • Käyttäjä
  • Viestejä: 625
    • Profiili
Vs: Openbox opas
« Vastaus #12 : 19.05.07 - klo:15.37 »
Eli teet sille samanlaisen käynnistimen kuin Openboxille GDM:ään.

Yksinkertainen mutta hieno!

Mutta saako tähän mitenkään edes menua... Tosin pypanelista ja gdeskleteistä saa nopeasti eniten käytetyt ohjelmat käynnistettyä mutta muut pitää käynnistää komentoriviltä.

Eikä se compiz-real näköjään kovin paljoa tehoja vie, myös kuutiota pyöräyttäessä tai ikkunaa liikutettaessa alle 2 %.
www.tehotuotanto.net

The surest sign that intelligent life exists elsewhere in the Universe is that none of it has tried to contact us.

eliasj

  • Käyttäjä
  • Viestejä: 4075
    • Profiili
Vs: Openbox opas
« Vastaus #13 : 19.05.07 - klo:15.46 »
Lainaus
Mutta saako tähän mitenkään edes menua... Tosin pypanelista ja gdeskleteistä saa nopeasti eniten käytetyt ohjelmat käynnistettyä mutta muut pitää käynnistää komentoriviltä.
Asenna vaikka siihen gnome-panel.
alias vililikku

pjotr

  • Käyttäjä
  • Viestejä: 625
    • Profiili
Vs: Openbox opas
« Vastaus #14 : 19.05.07 - klo:16.09 »
Asenna vaikka siihen gnome-panel.

Kiitos! Mutta nyt ulos, aurinko paistaa!  :)
www.tehotuotanto.net

The surest sign that intelligent life exists elsewhere in the Universe is that none of it has tried to contact us.

Stupido

  • Käyttäjä
  • Viestejä: 176
  • Gutsy Gibbon
    • Profiili
Vs: Openbox opas
« Vastaus #15 : 21.05.07 - klo:19.08 »
Kun valitsen kirjautumisruudista openboxin ja kirjaudun, tulee vain keltainen eikä tapahdu mitään. Ctrl+Alt+Backspacella pääsen takaisin kirjautumisruutuun.

Ubuntun käyttäjä jo vuodesta 2006.

Zhraelyn

  • Vieras
Vs: Openbox opas
« Vastaus #16 : 21.05.07 - klo:19.39 »
Sehän on se oletus, ei siinä alussa ole mitään erikoisempaa. Sitten vaan hiiren oikeaa korvaa ja terminaaliin.  ;D Vai koititko sitä eikä silloin tapahdu mitään?
« Viimeksi muokattu: 21.05.07 - klo:19.45 kirjoittanut Jan1 »

Clonk

  • Käyttäjä
  • Viestejä: 21
    • Profiili
Vs: Openbox opas
« Vastaus #17 : 12.06.07 - klo:12.05 »
Koodia: [Valitse]
[code][quote author=Jan1 link=topic=10145.msg72243#msg72243 date=1178383407]
OPENBOX TUTORIAALI

Aluksi tahdon kiittää raimoa, joka neuvoi minua alunperin openboxin käytössä. Ilman häntä olisin luultavasti kyllästynyt jo alussa. Paljon sitä silloin taisteltiin ja raimo korjaili vesipumppua joka oli poksahtanut ja taisipa tuo käydä omaa taisteluaan jotain kottikärryn rengasta vastaan. Kiitos kärsivällisyydestä.


Openbox on hyvin kevyt ikkunointiohjelma, X-ikkunointia tukeville käyttöjärjestelmille. Jos et ole valmis työpöytään, jota säädellään päätteen kautta varsin paljon tekstieditorin avulla, tämä opas ei ole sinulle. Openbox ei ole sinulle "se oikea."

Openboxin asennus:

Se on helppoa, aukaise pääte (terminal) ja kirjoita/kopioi siihen tämä:

[code]sudo apt-get install openbox openbox-themes obconf adesklets idesk rox-filer pypanel

Toimenpiteen jälkeen voit kirjautua ulos ja kirjautua Openboxin puolelle, istunnot kohdasta valitset Openboxin.

Nyt kun Openbox on asennettuna ja kaikki muut tarvittavat, joita tässä tutossa tarvitaan, katsotaan miten saat itsellesi taustakuvan:

Koodia: [Valitse]
cd
cp /usr/share/idesk/dot.ideskrc ~/.ideskrc
gedit .ideskrc
#Vaihdat nyt tulevan taustakuvan nimen Bacground.File riviin. Eli taustakuvan pitää olla samalla nimellä.
Background.File: ~/.idesktop/rain.jpg
cd ~/.idesktop
mkdir .idesktop

#Nyt haetaan haluamasi kuva, sen pitää olla TÄYSIN samalla nimellä tai se ei toimi. Nimenhän voi aina muokata.
wget http://www.linuxwallpapers.org/linux/rain.jpg
#käynnistä idesk ja taustakuva tulee näkyviin.
idesk &

adeskletit, asennetaan ne:

Koodia: [Valitse]
cd
mkdir adesklets
cd adesklets
wget http://switch.dl.sourceforge.net/sourceforge/adesklets/weather-0.0.4.tar.bz2
wget http://switch.dl.sourceforge.net/sourceforge/adesklets/modubar-0.0.1.tar.bz2
#puretaan ladatut tavarat, ole edelleen samassa hakemistossa.
tar -xvvf weather-0.0.4.tar.bz2
tar -xvvf modubar-0.0.1.tar.bz2

#Asetuksia pitäisi vielä säätää, mutta rekataan eka adskletit:
cd weather-0.0.4
#Nyt sinun pitäisi olla ~/adesklets/weather-0.0.4 hakemistossa.
./weather.py
#Paina r, mitään erikoista ei vielä tapahdu.
(tuossa tulee ongelmia)
[/code]
cd adesklets
cd modubar-0.0.1
#Nyt sinun pitäisi olla ~/adesklets/modubar-0.0.1 hakemistossa.
./modubar.py
#Nyt taas rekataan, r ja entteriä.
[/code]

Varmista että sinun ~/.adesklets tiedosto näyttää kutakuinkin samalta kuin minulla on (editorisi ~/.adesklets )
Lainaus
# This is adesklets configuration file.
#
# It gets automatically updated every time a desklet main window
# parameter is changed, so avoid manual modification whenever
# a desklet is running. In fact, manual changes to this file
# should rarely be needed. See `info adesklets'.

[/home/jani/adesklets/weather-0.0.4/weather.py]
id=0 screen=0 x=0 y=0

[/home/jani/adesklets/modubar-0.0.1/modubar.py]
id=0 screen=0 x=0 y=0

(MUISTA VAIHTAA POLUT OIKEAKSI!! Eli janin tilalle sinun tunnuksesi )

Modubarin kuvakkeiden käynnistyskäskyt voi säätää mieleisekseen: ~/adesklets/modubar-0.0.1/icons -- Tänne halutut kuvakkeet.
~/adesklets/modubar-0.0.1/config.txt  -- Tähän tiedostoon säädöt. Käyntiin lähtee Openboxin puolella näin: adesklets. Pypanel käynnistyy kirjoittamalla päätteeseen pypanel. Se paneli tulikin nyt alareunaan, joten päätteessä ctrl+c yhdistelmällä sulje se. Se piti käynnistää vain sen takia, että asetustiedosto syntyi. Muokkaa:
Koodia: [Valitse]
tekstieditorisi ~/.pypanelrc etsi sieltä P_LOCATION ja muuta siihen 0. Nyt paneeli tulee ylös.

idesk ikonit: Ikoneiden periaate on se, että jokaisella ikonilla on oma *.Ink tiedostonsa sekä tietenkin kuvansa ~/.idesktop hakemistossa. Esimerkkiä:

Lainaus
table Icon
  Caption: Ubuntulandia
  Command: firefox http://ubuntu.com/
  Icon: /usr/share/pixmaps/firefox.png
  Width: 48
  Height: 48
  X: 33
  Y: 68
end



Tässä minun ~/.ideskrc ja ~/.pypanelrc josta voi ottaa mallia, oikeastaan tämä on ihan raimon tekemä alunperin, mutta otin tämän toisen koneen (raato) johon silloin kesällä openboxin pistin. Myöhemmin voin lisätä ihan kokonaan itse väkertämän.

Tätä kun tutkailee pystyy huomaamaan, että fonttia on säädetty paremmaksi ja vihreäksi sekä taustakuvan mode on scale. Tätä käyttämällä pääset helpoimmalla.

Lainaus
table Config
  FontName: VeraBd
  FontSize: 14
  FontColor: #60C060
  ToolTip.FontSize: 14
  ToolTip.FontName: VeraBd
  ToolTip.ForeColor: #000000
  ToolTip.BackColor: #FFFFFF
  ToolTip.CaptionOnHover: false
  ToolTip.CaptionPlacement: Right
  Locked: false
  Transparency: 60
  Shadow: false
  ShadowColor: #000000
  ShadowX: 1
  ShadowY: 1
  Bold: true
  ClickDelay: 300
  IconSnap: true
  SnapWidth: 10
  SnapHeight: 10
  SnapOrigin: BottomRight
  SnapShadow: false
  SnapShadowTrans: 200
  CaptionOnHover: false
  CaptionPlacement: bottom
  FillStyle: none
  Background.Delay: 0
  Background.Source: None
  Background.File: ~/.idesktop/rain.jpg
  Background.Mode: Scale
  Background.Color: #CCDCCC
end

table Actions
  Lock: control right doubleClk
  Reload: middle doubleClk
  Drag: left hold
  EndDrag: left singleClk
  Execute[0]: left doubleClk
  Execute[1]: right doubleClk
end

~/.pypanelrc :

Sitä on muokattu jo enemmän, fontit on nimittäin isonnettu ja värejä on säädetty jne. Tiedostossa ei saa olla ääkkösiä, edes kommenteissa joten muistakaapa se!

Lainaus
#------------------------------------------------------------------------------
#
#                         PyPanel v2.4 Configuration
#
# This configuration file is a Python script that will be executed when
# PyPanel is started.  In order for PyPanel to start properly, make sure that
# this file contains proper Python formatting and no syntax errors.
#------------------------------------------------------------------------------
VERSION         = 2.4           # Config file version

#------------------------------------------------------------------------------
# Colors: Format is hex triplet - 0xrrggbb
#------------------------------------------------------------------------------
BG_COLOR        = "0xc6f6c6"    # Panel background and tinting color
TASK_COLOR      = "0x80B080"    # Normal task name color
FOCUSED_COLOR   = "0x80C080"    # Focused task name color
SHADED_COLOR    = "0x808080"    # Shaded task name color
MINIMIZED_COLOR = "0x808080"    # Minimized task name color
DESKTOP_COLOR   = "0x80B080"    # Desktop name color
CLOCK_COLOR     = "0x80B080"    # Clock text color
LINE_COLOR      = "0x606060"    # Vertical line color

# Text Shadow Colors
TASK_SHADOW_COLOR      = "0xffffff"
FOCUSED_SHADOW_COLOR   = "0xffffff"
SHADED_SHADOW_COLOR    = "0xffffff"
MINIMIZED_SHADOW_COLOR = "0xffffff"
DESKTOP_SHADOW_COLOR   = "0xffffff"
CLOCK_SHADOW_COLOR     = "0xffffff"

#------------------------------------------------------------------------------
# Panel Spacing and Location Options: Measured in pixels
#------------------------------------------------------------------------------
P_LOCATION      = 0             # Panel placement: 0 = top, 1 = bottom
P_WIDTH         = 0             # Panel width: 0 = Use full screen width
P_START         = 0             # Starting X coordinate of the panel
P_SPACER        = 6             # Spacing between panel objects
P_HEIGHT        = 24            # Panel height

#------------------------------------------------------------------------------
# Icon Size Options: Measured in pixels
#------------------------------------------------------------------------------
I_HEIGHT        = 16            # Panel application icon height
I_WIDTH         = 16            # Panel application icon Width
APPL_I_HEIGHT   = 24            # Application launcher icon height
APPL_I_WIDTH    = 24            # Application launcher icon width
TRAY_I_HEIGHT   = 24            # System tray icon height (usually 16 or 24)
TRAY_I_WIDTH    = 24            # System tray icon width  (usually 16 or 24)
                                # If TRAY_I_WIDTH is set to 0, then the
                                # width specified by the tray app will be used
                               
#------------------------------------------------------------------------------
# Panel Clock Format: 'man strftime' for detailed formatting options and help
#------------------------------------------------------------------------------
CLOCK_FORMAT    = "%d.%m.%Y"    # Ex: 2004-09-25 17:45 now %d.%m.%Y = 21.07.2006

#------------------------------------------------------------------------------
# Clock Delay: Seconds between each clock update during periods of inactivity
#------------------------------------------------------------------------------
CLOCK_DELAY     = 20

#------------------------------------------------------------------------------
# Hidden Application List: Apps listed here will not be display on the panel
# The application name is its WM_CLASS name, use 'xprop' to find WM_CLASS
# Ex: ["xmms", "xine", "gDesklets"]
#------------------------------------------------------------------------------
HIDE_LIST       = []           
                   
#------------------------------------------------------------------------------
# Hidden Panel Size: Size of the panel when it's hidden/minimized
#------------------------------------------------------------------------------
HIDDEN_SIZE     = 2

#------------------------------------------------------------------------------
# Panel Text Font: This option takes either a traditional or Xft font string
# Ex: "-schumacher-clean-medium-r-normal-*-12-*-*-*-*-*-*-*"
#     "aquafont-8"
#------------------------------------------------------------------------------
FONT            = "bitstream vera sans-13"

#------------------------------------------------------------------------------
# Show All Applications: Show apps from all desktops or just the current
# 0: Disabled - Only applications on the current desktop will be displayed
# 1: Enabled  - Selected apps are moved to the current desktop
# 2: Enabled  - Current desktop is changed to the selected apps desktop
#------------------------------------------------------------------------------
SHOWALL         = 0             # 0, 1 or 2 - see descriptions above

#------------------------------------------------------------------------------
# Show Minimized/Iconified Applications: Show only minimized apps or all apps
# 0: Disabled - Show all applications on the panel
# 1: Enabled  - Show only minimized apps on the panel
#------------------------------------------------------------------------------
SHOWMINIMIZED   = 0

#------------------------------------------------------------------------------
# Application Icon List: List of custom icons for specific applications
# The application name is its WM_CLASS name, use 'xprop' to find WM_CLASS
#
# The "default" entry is used for applications with no icon.  If left "",
# PyPanel will use the default icon distributed with the source.
#
# Add entries using the following format -
#     "<application name>" : "<full path to icon>",
#------------------------------------------------------------------------------
ICON_LIST       = {
                   "default" : "",
                   "example" : "/usr/share/data/images/audio.png",
                  }
                 
#------------------------------------------------------------------------------
# Application Launch List: Ordered list of icons and applications for the
#                          application launcher.
#
# Add entries using the following format -
#     ("<executable>", "<full path to icon>")
#------------------------------------------------------------------------------
# katso /usr/share/pixmaps siella on kuvakkeita mm.
#/usr/share/pixmaps/gnome-terminal.png
# ("komento", "kuvake"),
# ("komento2", "kuvake2"),

LAUNCH_LIST     = [
                   ("epiphany", "/home/TUNNUS/.idesktop/firefox_green.png"),
                   ("gnome-terminal", "/home/TUNNUS/.idesktop/terminal_green.png"),
                   ("leafpad ~/.readme", "/home/TUNNUS/.idesktop/doc_green.png"),
                  ]

#------------------------------------------------------------------------------
# Background Alpha/Shade Level: 0 (Fully Translucent) -> 255 (Fully Opaque)
# BG_COLOR is used for tinting
#------------------------------------------------------------------------------
SHADE           = 35

#------------------------------------------------------------------------------
# Misc. Options: 1 = Enabled/Yes, 0 = Disabled/No
#------------------------------------------------------------------------------
ABOVE           = 1             # Panel is always above other apps #On theTop
APPICONS        = 1             # Show application icons
AUTOHIDE        = 0             # Autohide uses the CLOCK_DELAY timer above
SHADOWS         = 0             # Show text shadows
SHOWLINES       = 0             # Show object seperation lines
SHOWBORDER      = 0             # Show a border around the panel

#------------------------------------------------------------------------------
# Desktop Names: Configure the names of your desktops
# If the option is [], PyPanel will attempt to use the desktop name specified
# by the XServer, if that fails it will use the desktop number as its name
# Ex. ["One", "Two", "Three", "Four", "Five", "Six", "Seven", "Eight"]
#------------------------------------------------------------------------------
DESKTOP_NAMES   = []

#------------------------------------------------------------------------------
# Panel Layout:       -----------------------------------
#                     [  1  ][  2  ][  3  ][  4  ][  5  ]
#                     -----------------------------------
#
# The panel layout is split into 5 sections numbered 1, 2, 3, 4 or 5 as shown
# in the diagram above.  Each of the following objects can be enabled by
# assigning it a section number or disabled by assigning it 0:
#------------------------------------------------------------------------------
DESKTOP         = 4             # Desktop name section
TASKS           = 2             # Task names section
TRAY            = 3             # System tray section
CLOCK           = 5             # Clock section
LAUNCHER        = 1             # Application launcher section

#------------------------------------------------------------------------------
#                       Button Event Function Definitions
#------------------------------------------------------------------------------
# Left click   - button 1
# Middle click - button 2
# Right click  - button 3
# Wheel up     - button 4
# Wheel down   - button 5
#
# changeDesktop(x)
# - Change Desktop: Increase or decrease the current desktop by 'x' amount
#
# toggleShade(task)
# - Shade or Unshade an application
#
# toggleHidden()
# - Minimize the panel to the top or bottom depending on its start location
#
# toggleMinimize(task, traise=1)
# - Minimize or Unminimize an application and optionally raise it
#
# taskRaise(task, focus=1)
# - Raise an application to the top of the window list and optionally focus it
#
# taskLower(task, focus=0)
# - Lower an app to the bottom of the window list and optionally focus it
#
# taskFocus(task)
# - Give focus to the selected application, if it has focus then minimize it
#
# showDesktop()
# - Toggle between hiding and unhiding ALL applications
#------------------------------------------------------------------------------

#----------------------------------
def desktopButtonEvent(pp, button):
#----------------------------------
    """ Button event handler for the panel's desktop object """
       
    if button == 1:
        pp.changeDesktop(-1)
    elif button == 2:
        pp.changeDesktop(2)
    elif button == 3:
        pp.changeDesktop(1)
    elif button == 4:
        pp.changeDesktop(1)
    elif button == 5:
        pp.changeDesktop(-1)
       
#--------------------------------
def clockButtonEvent(pp, button):
#--------------------------------
    """ Button event handler for the panel's clock object """
   
    if button == 1:
        os.system("xclock &")
    elif button == 2:
        pp.showDesktop()
    elif button == 3:
#        pp.toggleHidden()
        pp.showDesktop() 
    elif button == 4:
        pp.showDesktop()
    elif button == 5:
        pp.showDesktop()
       
#--------------------------------
def panelButtonEvent(pp, button):
#--------------------------------
    """ Button event handler for the panel with no active tasks """
   
    if button == 1:
        pass
    elif button == 2:
        pass
    elif button == 3:
        pass
    elif button == 4:
        pass
    elif button == 5:
        pass
       
#-------------------------------------
def taskButtonEvent(pp, button, task):
#-------------------------------------
    """ Button event handler for the panel's tasks """
   
    if button == 1:
        pp.taskFocus(task)
    elif button == 2:
        # Destroy the application
        task.obj.destroy()
    elif button == 3:
        # Ex. - XMMS doesn't shade, so we want to minimize it instead and
        #       still use button 3 to shade other applications
        #       task.tclass is the tasks class name (WM_CLASS)
        if "xmms" in task.tclass:
            pp.toggleMinimize(task)
        else:
            pp.toggleShade(task)
    elif button == 4:
        pp.taskRaise(task, focus=1)
    elif button == 5:
        pp.taskLower(task, focus=0)
       

Tämän jälkeen työpöytäsi pitäisi näyttää suunnilleen tältä:


(Klikkaa kuvaa, se aukeaa uuteen ikkunaan ja suurenee)

Otan mielelläni palautetta vastaan, tulen lisäämään tähän vielä asioita, tässä nyt jonkinlainen alku. Kehittävää palautetta odotellen;

- Jan1


[/quote]

eliasj

  • Käyttäjä
  • Viestejä: 4075
    • Profiili
Vs: Openbox opas
« Vastaus #18 : 15.06.07 - klo:22.14 »
Hei!

Laitoin tämän ohjeen Ubuntu Wikiin. http://www.ubuntu-fi.org/Wiki/Openbox-opas Toivoisin, että joku voisi lisätä nuo pitkät tekstipätkät ohjeeseen. Kun itse kopioin tekstit ohjeeseen, rivinvaihdot eivät menneet oikein. Muutenkin toivoisin, että ohjeen ulkoasua ja sanamuotoja parannettaisiin.
alias vililikku

eGetin

  • Käyttäjä
  • Viestejä: 1093
  • Milloin mitäkin
    • Profiili
Vs: Openbox opas
« Vastaus #19 : 28.08.07 - klo:21.06 »
Anteeksi pienoinen nosto...

Mutta tuli semmoista onkelmaa, muuten toimii ihan loistavasti, mutta miten saan vaihdettua gdm:n teeman, ja miten sen saa käynnistämään openboxin?
Pöytäkone: Intel i7 920 | Asus P6X58D Premium | 12Gb DDR3 1600MHz | Asus Radeon HD 6950 1Gb | 60GB OCZ Vertex 2 SSD + 2TB WD Caviar Green + Samsung 830 120GB
HTPC: Intel C2D E4400 | Asus P5B | 4Gb DDR2 800MHz | Asus Geforce GT210 | 500GB WD Caviar GP
Kannettava: Asus Eee PC 1225B