View Single Post
Old 10-01-2013, 07:15 AM   #20
baf
Evangelist
baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.baf ought to be getting tired of karma fortunes by now.
 
Posts: 405
Karma: 2330752
Join Date: May 2012
Device: kt
Quote:
Originally Posted by twobob View Post
You run the KUAL button, Awesome will restart... after that any apps you start that dont have correct titles (L:Blah...) will be automagically renamed on-the-fly until you reboot.


Well that's it. feel free to IMPROVE THIS. Please.
Interesting idea!

Wouldn't it be enough to substitute custom app name with proper one within lua script instead of running external script and changing it with xdotool? I mean to deceive layer manager without really changing the name.

I did a very simple test which works. I just checked simple "hello world". I am not sure what would happen with multiwindow apps. But it still might be possible to handle within lua script.

EDIT: Tried gtactoe. Seems it works for simple apps with dialog windows.

Code:
--- awesome/lab126LayerLogic.lua.org
+++ awesome/lab126LayerLogic.lua
@@ -132,7 +132,13 @@

     -- validate
     if str == nil or not stringStartsWith(str, "L:") then
-        return nil
+        if str == nil or string.match(str,"(webreader|pillowd|kb)") then
+        	log ("FRONTER Skipping: ".. tostring(str))
+        	return nil
+        else
+        	log ("FRONTER Renaming: ".. tostring(str))
+        	str = "L:A_N:application_ID:test"
+        end
     end

     local entries = {}

Last edited by baf; 10-01-2013 at 07:54 AM.
baf is offline   Reply With Quote