Re: amixer hangs
Le lundi 14 novembre 2011 à 23:53 -0200, Daniel Hilst a écrit : > On 11/14/2011 04:28 PM, Adrian C. wrote: > > On Mon, 14 Nov 2011, Daniel Hilst Selli wrote: > > > >> Thanks Adrian, I'm installing awesome from git > > > > But from 3.4 branch, if you want stable. > > > > Yes, I do thanks! I have already installed it, but now I'm facing > problems with my rc.lua. Like widget() and > awful.widget:set_color_gradient() are nil, is there any docs for new api? > > > []'s > You can found the luadoc on your system. For me it's located here : file:///usr/share/doc/awesome/luadoc/index.html By the way, if you need a simple way to control pulseaudio sink volume, you can use my little command tool pamixer [1]. Clément Démoulins [1] https://github.com/cdemoulins/pamixer -- Clef GPG : 0xDD51E028 signature.asc Description: This is a digitally signed message part
Re: problem when nvidia-settings
Le lundi 12 décembre 2011 à 10:54 +0100, Charles Prévot a écrit : > Hi, > Sorry for the late reply, but I have the same problem, and my workaround is > Alt+O to click OK on the invisible confirmation window > > > On Tue, Dec 6, 2011 at 3:54 PM, Michael wrote: > > > Open a terminal and use xkill or killall to shutdown the nvidia-settings > > window after you hit apply, your settings will remain applied. > > Or remove the confirm dialogbox float state (by default; CTRL+MOD+SPACE), > > probably also possible with awful.rules. > > > > > > Michael > > > > > > On Tue, 06 Dec 2011 15:38:08 +0100, Ekram wrote: > > > > Hi, > >> > >> I am getting really tired of some behavior of the window manager. > >> When i am using nvidia-settings to enable the twinview for other screen > >> i have to apply several times to get the little > >> OK confirmation. Again after finishing > >> work when i like to disable the twinview then again i have to apply > >> several > >> times > >> to get little OK confirmation windows. It seems that the little OK > >> confirmation window > >> is floating or lost somewhere get back after several times. Even there is > >> problem > >> that some window not get back to right position like automacally not fit > >> the screen > >> when i changed to twinview and vice-versa. Please help me to sort it out. > >> It really annoying. > >> > >> Your help will be greatly appreciated. > >> Thanks in advance. > >> > >> /Ekram > >> > > > > > > -- > > Using Opera's revolutionary email client: http://www.opera.com/mail/ > > > > -- > > To unsubscribe, send mail to > > awesome-unsubscribe@naquadah.**org > > . > > Hi, I had the same problem with nvidia-settings and now i use the tool disper [1]. It's like xrandr but it work with driver nvidia and the twinview mode. Clément Démoulins [1] http://willem.engen.nl/projects/disper/ -- Clef GPG : 0xDD51E028 signature.asc Description: This is a digitally signed message part
Re: ANN: Menubar - decent application menu for Awesome
Le samedi 07 janvier 2012 à 19:19 +0200, Alexander Yakushev a écrit : > Dear community, > > As my body temperature floated around 39-40 degrees Celsius I found > nothing better to do than to pimp my Awesome a little further. That's > how this abomination (composed of modified freedesktop.menu and > awful.util.prompt) was born. > > Now to the serious part. Menubar is a dmenu-like menu written > exclusively for Awesome (using Awesome facilities). It is cooler than > debian.menu (not distro-specific), it is controllable from keyboard, it > has icons. > > More information and installation guide resides here: > http://awesome.naquadah.org/wiki/Menubar > > Hope this becomes useful to someone. > > Best regards, > Alexander > Hi, Could you try to provide a version of Menubar for the git version of awesome. Last version of awesome use a new API for the wibox and the layouts. I tried myself to update from your code but not successfully. Thanks, Clément Démoulins -- Clef GPG : 0xDD51E028 signature.asc Description: This is a digitally signed message part
Re: ANN: Menubar - decent application menu for Awesome
Le mardi 10 janvier 2012 à 12:51 +0200, Alexander Yakushev a écrit : > 2012/1/10 Clément Démoulins > > > > > Hi, > > > > Could you try to provide a version of Menubar for the git version of > > awesome. Last version of awesome use a new API for the wibox and the > > layouts. > > I tried myself to update from your code but not successfully. > > > > Thanks, > > > > Clément Démoulins > > > > I'll fire up a virtual machine today with git version of awesome and try to > do that. > > Though I'm a bit anxious myself to migrate to git-version. Is there a place > to read all implications connected with it? You can read the git logs and commits starting with the commit: 2eae7e5cf467d330ad0bc20b5e11a14273c3a446 I join a patch that almost working. Function menubar:show() is displaying a wibox but with no content, just the “Run app:”. And there are some bugs. -- Clef GPG : 0xDD51E028 From 4d446ae1d4cf8745eb4e1833c9c82c40cbacaae0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20D=C3=A9moulins?= Date: Tue, 10 Jan 2012 13:21:31 +0100 Subject: [PATCH 1/1] Convert menubar to work on awesome-git, the menubar is almost working. --- init.lua | 39 +++ prompt.lua | 16 2 files changed, 31 insertions(+), 24 deletions(-) diff --git a/init.lua b/init.lua index 3e2445b..6d09fa6 100644 --- a/init.lua +++ b/init.lua @@ -5,7 +5,6 @@ -- Grab environment we need local capi = { widget = widget, - screen = screen, image = image, client = client, wibox = wibox, @@ -17,6 +16,10 @@ local theme = require("beautiful") local menu_gen = require("menubar.menu_gen") local prompt = require("menubar.prompt") local awful = require("awful") +local wibox = require("wibox") +local naughty = require("naughty") +local cairo = require("oocairo") +local common = require("awful.widget.common") local tonumber = tonumber local io = io local string = string @@ -38,7 +41,7 @@ instance = { prompt = nil, widget = nil, wibox = nil } -common_args = { w = { layout = awful.widget.layout.horizontal.leftright }, +common_args = { w = wibox.layout.fixed.horizontal(), data = setmetatable({}, { __mode = 'kv' }), widgets = { imagebox = { }, textbox = { ["margin"] = { ["left"] = 5, @@ -83,13 +86,19 @@ local function perform_action(o) end local function initialize() - instance.wibox = capi.wibox({}) + instance.wibox = awful.wibox({}) instance.widget = new() instance.wibox.ontop = true - instance.prompt = awful.widget.prompt({ layout = awful.widget.layout.horizontal.leftright }) - instance.wibox.widgets = { instance.prompt, - instance.widget, - layout = awful.widget.layout.horizontal.leftright } + instance.prompt = awful.widget.prompt() + local layout = wibox.layout.fixed.horizontal() + layout:add(instance.prompt) + layout:add(instance.widget) + instance.wibox:set_widget(layout) +end + +function file_exist(path) +local f = io.open(path, "r") +if f ~= nil then io.close(f) return true else return false end end function refresh(use_cache) @@ -113,7 +122,7 @@ function refresh(use_cache) local icon_path = f:read("*line") local category = tonumber(f:read("*line")) table.insert(menu_entries, { name = name, cmdline = cmdline, - icon = icon_path ~= "" and capi.image(icon_path) or nil, + icon = icon_path ~= "" and file_exist(icon_path) and cairo.image_surface_create_from_png(icon_path) or nil, category = category }) end end @@ -122,15 +131,14 @@ end function show(screen) if not instance.wibox then initialize() - elseif instance.wibox.screen then -- Menu already shown, exit + elseif instance.wibox.visible then -- Menu already shown, exit return elseif not cache_entries then refresh() end -- Set position and size - instance.wibox.screen = screen or mouse.screen - local scrgeom = capi.screen[instance.wibox.screen].workarea + local scrgeom = capi.screen[mouse.screen].workarea local x = g.x or scrgeom.x local y = g.y or scrgeom.y instance.wibox.height = g.height or 20 @@ -139,7 +147,6 @@ function show(screen) current_item = 1 current_category = nil - instance.wibox.screen = screen or mouse.screen menulist_update() prompt.run({ prompt = "Run app: " }, instance.prompt.widget, function(s) end, nil, awful.util.getdir("cache&quo
Re: How to execute a program when shutting the computer down?
Le 10/04/2012 15:27, Bill Sun a écrit : > Hi, > > Currently I'm sharing my computer with someone, and we use different > window manager/desktop environment. I want to save alsa volume level on > a per-user basis, so I need to execute `alsactl store -f ~/.asoundrc` > when logging out. > > Since I use slim as my 'login manager', I thought I can use .xinitrc to > achieve that. I added that command to the very end of my .xinitrc, after > `ck-launch-session awesome` (see my attachment). > > If I just logout, then everything seems OK---my current volume level > would be successfully stored. If, however, I shut my computer down via > an awesome key binding (I created a shell script that uses dbus/ > consolekit command to poweroff; then use `awful.key({ modkey }, "]", > function () awful.util.spawn_with_shell(/home/user1/bin/poweroff)) to > assign that script to a key), then my current volume level wouldn't be > saved. The only message I saw is `xinit: connection to X closed` during > shutting down. > > The guy who shares computer with me uses KDE, and he uses basically the > same .xinitrc (except replace `awesome` with `startkde`). KDE handles > this correctly---either just logging off or shutting down in KDE, his > volume level would be saved. > > So, how to achieve this function in awesome? > > -Bill When the computer is shutting down, a SIGTERM is send to all the process and a few second later a SIGKILL is send. You should try to catch the SIGTERM in the .xinitrc script using the command “trap” (man trap). Clément -- Clef GPG : 0xDD51E028 signature.asc Description: OpenPGP digital signature
Re: Un-minimizing a window won't work iff in alternative keyboard layout
Le 23/04/2012 05:16, daspostloch a écrit : > Hi all, > > since a recent Arch linux system (including awesome) update, > i cannot un-minimize a window minimized with mod-n anymore > *iff i am in another than my standard US keyboard setting*. > That is, when I minimize a window and want to click on the > tab bar representation of the minimized client to un-minimize > it, nothing happens. It is as if the mouse click does not work > (but all other mouse clicks work just fine). Any ideas are much > appreciated.. > > I am not an expert on the hal/fdi policy things, and realize > that a lot changed recently with hal on arch - but since > everything else is working fine, i'm starting from the > assumption that it is an awesome issue? In my > /etc/hal/fdi/policy/10-keymap.fdi , I have these lines: > > type="string">grp:shifts_toggle,terminate:ctrl_alt_bksp > us,de > ,nodeadkeys > > and here are my stats: > > $ awesome --version > awesome v3.4.11 (Pickapart) > • Build: Feb 6 2012 07:50:23 for x86_64 by gcc version 4.5.2 (test@) > • D-Bus support: ✔ > > $ uname -a > Linux hostname 3.3.2-1-ARCH #1 SMP PREEMPT Sat Apr 14 09:48:37 CEST 2012 > x86_64 Intel(R) Core(TM)2 Duo CPU P8700 @ 2.53GHz GenuineIntel GNU/Linux > > Thanks for any ideas on this, > Paul > Hi, I don't know if it is related or if it will fix your problem but you can uninstall hal. Xorg is now (it's not very new) using udev. For more information, the Archlinux wiki documentation about xorg is up to date. Clément -- Clef GPG : 0xDD51E028 signature.asc Description: OpenPGP digital signature
Re: Dependencies
Le 24/04/2012 23:40, David Gomes a écrit : > I just tried to build awesome WM from git repository ( > http://aur.archlinux.org/packages.php?ID=13916), but it needs lua-oopango. > > However, I can't build lua-oopango (I get this error: > http://pastebin.com/KFwj4L3W). > > How's everybody managing to build Awesome and lua-oopango? > > (I tried both Lua 5.1.5 and Lua 5.2) > I'm using Archlinux and the package awesome-git without any problem. If you want, i can provide you a binary package. Clément Démoulins -- Clef GPG : 0xDD51E028 signature.asc Description: OpenPGP digital signature
Re: Sound without desktop environment
Le 01/05/2012 11:18, Hans Georg Schaathun a écrit : > On Tue, 1 May 2012 11:03:27 +0200, Zsolt Udvari >wrote: > : What soundsystem do you use? Maybe it can be pulse/jack problem. > : What is the sound output plugin of your programs? > > Sorry, I am not familiar with the jargon, so I am not quite sure > what you are asking about. I have done no more than installing > ubuntu packages until it worked under xfce. > > But since > % sudo aplay file > gives sound; and > % aplay file > does not, it must be a pure privilege issue. > > All I know about the system is this: > % sudo aplay -l > [sudo] password for georg: > List of PLAYBACK Hardware Devices > Home directory /home/georg not ours. > card 0: Intel [HDA Intel], device 0: ALC892 Analog [ALC892 Analog] > Subdevices: 1/1 > Subdevice #0: subdevice #0 > card 0: Intel [HDA Intel], device 1: ALC892 Digital [ALC892 Digital] > Subdevices: 1/1 > Subdevice #0: subdevice #0 > card 0: Intel [HDA Intel], device 3: HDMI 0 [HDMI 0] > Subdevices: 1/1 > Subdevice #0: subdevice #0 Try to start at login time the script “start-pulseaudio-x11” (in your .xinitrc for example). -- Clef GPG : 0xDD51E028 signature.asc Description: OpenPGP digital signature
Re: awesome git
Le 10/05/2012 01:52, Gerald Klein a écrit : > Hi, I am running git now with the changes, where can I find an updated > object reference? The current one don't match at all. I would like to > reconfigure things like my clock etc, and also get to know the new schema. > > thanks in advance for your help. > > --jerry > > -- > > Gerald Klein DBA > > contac...@geraldklein.com <mailto:contac...@geraldklein.com> > > www.geraldklein.com <http://geraldklein.com/> > > j...@zognet.com <mailto:j...@zognet.com> > > 708-599-0352 > > > Linux registered user #548580 > > > Hi, Are-you talking about the luadoc ? You can found a local version on your system at “/usr/share/doc/awesome/luadoc”. Clément Démoulins -- Clef GPG : 0xDD51E028 signature.asc Description: OpenPGP digital signature
Re: Multi-head setup
On 15/10/2012 18:07, Marco wrote: > Hi everybody, > > I feel a little awkward asking about it on the mailing list, given that > there's a big entry in the wiki and Google is not stingy with information, > either. > > What I want > === > > My situation is that I have a laptop with Intel graphics adapter and an > external screen connected via display port (I think). I don't know in advance > the model or which resolution the screen has, this rules out any static > configuration. I'd like to connect the external screen without restarting the > Xserver and have another nine independent tags. I want to be able to send > windows from my current screen to the other one. > > What I've tried so far > == > > When I connect the second screen awesome restarts and I have a strange setup. > The external screen is placed at the right of my laptop monitor and entirely > black. However, when I leave the laptop monitor at the right edge, the mouse > cursor is displayed on the external monitor. But I cannot do anything. I can > not move any window to this screen and there is no awesome wibox with the > tags. It seems like awesome is not “running” on this screen. > > Using XRandR > > > As suggested in the wiki page “Using_Multiple_Screens” I ran > > xrandr --output HDMI1 --mode 1280x1024 --right-of LVDS1 > > Nothing changed. It seems that this is the default mode when an external > screen is being connected. I tried to push the “XF86Display” button on my > laptop, it seems to cycle through all possible xrandr modes. None of them does > what I want. Cloning is not what I want and does not work with screens with > different resolutions and the “--right-of” mode behaves weird as described, I > only have a cursor. > > Using Xinerama > -- > > To activate Xinerama I quit my Xserver and ran `Xorg -configure`. I then > placed the file in `/etc/X11/xorg.conf` and added the line `Option "Xinerama" > "true"` to `ServerLayout`. After a restart I had exactly what I wanted. A > second, independent awesome on the second screen. I quickly discovered that > Xinerama does not like connecting and disconnecting the screens on-the-fly. I > always had to restart the Xserver when I connect a screen. I found the > following statement on Wikipedia: > >> Static configuration - physical screens cannot be added or removed >> dynamically […] > > This makes Xinerama unusable for me. > > The solution ?? > === > > I am pretty sure this is a not too exotic setup, but I fail to set it up > correctly. Maybe some of you with a multi-head setup can give me a nudge in > the right direction. Can I use XRandR for this? If yes, with which > configuration? Is there another solution I didn't try? > > If you are reading this I appreciate your interest and apologize for this > too long post. > > I am running awesome debian/3.4.13-1 > > > Kind regards > > Marco > > > Did you try to force a restart, i already experienced some weird things with the auto restarting of awesome (or maybe it was related to xorg or the nvidia driver it's hard to tell). Clément -- Clef GPG : 0xDD51E028 signature.asc Description: OpenPGP digital signature
Re: How do you people handle sound? Show your solution
On 19/10/2012 02:42, Juan Antonio Zuloaga Mellino wrote: > I can't remember if I made it, stole it or both, but this is my ugly > workaround for pulse audio > > calling paMuteToggle() doest what you'd expect. > With no parameters changes all the sinks to the opposite state of the > first sink. > You can use a sink as an argument. > > HOW TO USE IT: > > require("pamute") > [...] > awful.key({ }, "XF86AudioMute",function () paMuteToggle() end ), > > > pamute.lua attached. > I write a little program to control the sound volume of pulseaudio: https://github.com/cdemoulins/pamixer % pamixer --help Allowed options: -h [ --help ] help message -s [ --sink ] arg choose a different sink than the default --source arg choose a different source than the default --default-source select the default source --get-volume get the current volume --set-volume arg set the volume --increase argincrease the volume --decrease argdecrease the volume --toggle-mute switch between mute and unmute --muteset mute --unmute unset mute --get-mutedisplay true if the volume is mute, false otherwise --list-sinks list the sinks --list-sourceslist the sources Using this program i create a widget to display the current volume and add some keybinding to control the volume. My module “pulseaudio.lua” is for the git version only. Clément -- Clef GPG : 0xDD51E028 local awful = require("awful") local wibox = require("wibox") local naughty = require("naughty") local util = require("util") local pulseaudio = {} local label = wibox.widget.textbox() local widget = wibox.widget.textbox() pulseaudio.widget = wibox.layout.fixed.horizontal() pulseaudio.widget:add(label) pulseaudio.widget:add(widget) local volume = 0 local muted = false local notification_id = nil local muted_notification_id = nil local pamixer = "pamixer" local sink = 0 local timer = timer local muted_icon = "/home/clement/.config/awesome/current_theme/icons/audio-volume-muted.png" local off_icon = "/home/clement/.config/awesome/current_theme/icons/audio-volume-off.png" local low_icon = "/home/clement/.config/awesome/current_theme/icons/audio-volume-low.png" local medium_icon = "/home/clement/.config/awesome/current_theme/icons/audio-volume-medium.png" local high_icon = "/home/clement/.config/awesome/current_theme/icons/audio-volume-high.png" local function update() local icon = "ð " -- speaker character if muted then icon = "ð " -- mute speaker character end local volume_text = util.textcolor(string.format("%02d%%", volume), util.gradient("#44FF44", "#FF", 30, 120, volume)) label:set_markup(icon) widget:set_markup(volume_text) end local function notify() local volume_icon = high_icon if volume == 0 then volume_icon = off_icon elseif volume <= 30 then volume_icon = low_icon elseif volume <= 60 then volume_icon = medium_icon end notification_id = naughty.notify({ text="Volume "..volume.."%", title="Volume", icon=volume_icon, replaces_id=notification_id }).id end local volume_timer = timer { timeout=3 } volume_timer:connect_signal("timeout", function() pulseaudio:update() end) function pulseaudio:register() volume_timer:start() end function pulseaudio:update() volume = tonumber(awful.util.pread(pamixer.." -s "..sink.." --get-volume") or 0) muted = awful.util.pread(pamixer.." -s "..sink.." --get-mute") == "true" update() end function pulseaudio:volume_up() volume = tonumber(awful.util.pread(pamixer.." -s "..sink.." --increase 5 --get-volume") or 0) if volume > 150 then volume = tonumber(awful.util.pread(pamixer.." -s "..sink.." --set-volume 150 --get-volume") or 0) end update() notify() end function pulseaudio:volume_down() volume = tonumber(awful.util.pread(pamixer.." -s "..sink.." --decrease 5 --get-volume") or 0) update() notify() end function pulseaudio:toggle_mute() muted = awful.util.pread(pamixer.." -s "..sink.." --toggle-mute --get-mute") == "false" update() if muted == true then muted_notification_id = naughty.notify({ text="Muted", title="Volume", icon=muted_icon, replaces_id=muted_notification_id }).id else muted_notification_id = naughty.notify({ text="Unmuted", title="Volume", icon=high_icon, replaces_id=muted_notification_id }).id notify() end end --pulseaudio.widget:connect_signal("button::press", function() --naughty.notify({text="Test", title="Titre"}) --pulseaudio.toggle_mute() --end) pulseaudio.widget:buttons(awful.util.table.join( awful.button({ }, 1, pulseaudio.toggle_mute), awful.button({ }, 4, pulseaudio.volume_up), awful.button({ }, 5, pulseaudio.volume_down) )) return pulseaudio signature.asc Description: OpenPGP digital si
Re: What's the ":" for in lua?
On 19/10/2012 10:43, Manuel Kasser wrote: > Hi, > I've got a question not especially concerning awesome, but I'm sure some > of you will know it: What's the ":"-operator for when I use it on an > object (e.g. string:name() if that is a valid example). > Searching for it with my standard search engine didn't help because I > get a lot of lua-tutorials and wiki-pages, but those where the ":" is > used to separate examples of code from the introductional text etc., > which doesn't really help and I had no luck in finding a useful wiki > page, where the operator is explained, just some, where it is declared > as a special operator. Could someone help me? > > Thanks in advance, > Manuel > See “3.4.9 - Function Calls” in the lua documentation : http://www.lua.org/manual/5.2/manual.html#3.4.9 Clément -- Clef GPG : 0xDD51E028 signature.asc Description: OpenPGP digital signature