Launching application without titlebar and window decorations
Use either Devil's Pie or Devilspie2 to remove the window decoration. Both will likely work for any application, otherwise will not work against applications with the client-side decoration.
Using Devil's Pie
For Devil's Pie, open a text editor and type the following code.
(if (is (application_name) "VLC media player") (undecorate))
Save as file at $HOME/.devilspie/filename.ds
with any filename of choice. Make sure the file extension is .ds
. Finally, run devilspie
in terminal to see the result.
Using Devilspie2
For Devilspie2, open a text editor and type the following code.
if (get_application_name()=="VLC media player") then
undecorate_window();
end
Save as file at $HOME/.config/devilspie2/filename.lua
with any filename of choice. Make sure the file extension is .lua
. Finally, run devilspie2
in terminal to see the result.
Devil's Pie vs. Devilspie2
If there is one thing that makes difference between these tools, it is the latter. Devilspie2 provides a convenient way to check the window name and application name for running applications, without having to run a separate command like wmctrl -l
from other tool.
To see the debug information with Devilspie2, add the following code in the .lua
file.
debug_print("Window name: " .. get_window_name());
debug_print("Application name: " .. get_application_name());
Exit running instance, then run devilspie2 -d
in Terminal will print something like below.
Running devilspie2 in debug mode.
[...]
Window Name: VLC media player
Application name: VLC media player
Window Name: Dictionary
Application name: xfce4-dict
See /usr/share/doc/devilspie2
for script example and more details.
Devil's Pie and Devilspie2 are both available in all repositories of Debian releases (oldstable, stable, testing, unstable), according to the Debian package search results.
Tested Devil's Pie and Devilspie2 in Debian 8 Xfce and Xubuntu 14.04 (both runs Xfce 4.10), and Devilspie2 in Linux Mint Debian Edition 3 (Cinnamon 3.8).
Related videos on Youtube
cvetozaver
Updated on September 18, 2022Comments
-
cvetozaver over 1 year
I am successfully loading and using an PKCS12 file Cert.pfx from Assets like this:
String certLocation = "certificates/Cert.pfx"; InputStream isCert = null; try { isCert = getAssets().open(certLocation); } catch (Exception e) { Log.d(TAG, "Could not get Assets"); } // Work with the certificate
I am trying to do the same now, but reading from a storage in Android.
File sdCard = Environment.getExternalStorageDirectory(); File dir = new File (sdCard.getAbsolutePath() + "/PrintableRSA"); File cert = new File(dir,"Cert.pfx"); InputStream isCert= null; try { isCert = new BufferedInputStream(new FileInputStream(cert)); isCert.close(); Log.d(TAG,"Sucsess!"); } catch (Exception e) { Log.d(TAG, "Could not load the file"); } // Same work with the certificate
The file loads sucsessfully, but When I further to work with isCert InputStream, loaded from storage, it does not work. I suspect that therefore the files are not equal.
I also tried with
InputStream isCert = FileInputStream(cert);
unsuccessfully.How can I fix this issue?
-
Selvin over 9 yearsit depends on what "does not work" means ...
-
greenapps over 9 yearsWhy are you referring to external memory as internal memory?
-
cvetozaver over 9 yearsBecause, android automatically chooses the internal one if external is not available. And this is what I want.
-
TNW over 8 yearsDoes this work?
-
anders over 8 yearsUnfortunately not. It puzzles me a bit that this is so hard to achieve. Mplayer manages to do it, but has other problems which makes it useless.
-
TNW over 8 yearsCould you run just
xprop
on bothvlc
andmplayer
? That should display properties of their windows - there's a chance you could copy something offmplayer
that will do the trick. -
anders over 8 yearsRunning with -noborder option on mplayer shows the motif hints: 0x3, 0x0, 0x0, 0x0, 0x0. Running VLC with the options above results in 0x3, 0x3e, 0x7e, 0x0, 0x0. Changing the hints doesn't really do much. I see that VLC receives a resize event, but thats it :(
-
Admin about 8 yearsRelated: KDE users refer to this post and Openbox users refer to another post.
-
-
cvetozaver over 9 yearsI checked my original code. I had an
this.myCert = isCert
between theisCert
declaration andisCert.close()
statement. I wrongfully thought that the InputStream gets copied at that point. I guess when theisCert
is closed, thethis.myCert
becomesnull
as well. Can you confirm this?