Xfce Forum

Sub domains
 

You are not logged in.

#1 2019-09-21 20:36:23

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

how to remove title bar from a non-terminal application?

how can i remove the title bar from an application other than xfce4-terminal?  turning of all title bars in that user is a usable solution in this case.

Offline

#2 2019-09-21 23:31:28

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 5,886

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

how can i remove the title bar from an application other than xfce4-terminal?  turning of all title bars in that user is a usable solution in this case.

You have 3 options here:

  1. Use a blank xfwm4 theme - it will remove all decorations. Basically:

    mkdir -p ~/.themes/blank/xfwm4 && touch ~/.themes/blank/xfwm4/themerc

    & select the "blank" theme from Settings Manager > Window Manager > Style.

  2. Use a theme that is specifically created to minimize or remove the title bar. Search through https://www.xfce-look.org/ for one that you like.

  3. Use DevilsPie and the "undecorate" action on all windows.

Offline

#3 2019-09-22 05:10:16

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

is there a way to tell which themes minimize or remove the title bar?  making it black me be just as good.  if there is a way to make dclock go full screen an still use a 720 pixel high font, that would work.  the goal is to have as black a screen as possible with a very large red LED style digital clock on it.  just for that one user.

Offline

#4 2019-09-22 06:59:38

Aravisian
Member
Registered: 2019-08-17
Posts: 132

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

is there a way to tell which themes minimize or remove the title bar?  making it black me be just as good.  if there is a way to make dclock go full screen an still use a 720 pixel high font, that would work.  the goal is to have as black a screen as possible with a very large red LED style digital clock on it.  just for that one user.

I could make a conky clock that does that. I know this by accident.

Offline

#5 2019-09-22 09:59:22

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 5,886

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

is there a way to tell which themes minimize or remove the title bar?

Search on "xfwm4 border only" and find https://www.xfce-look.org/p/1016214/ or https://www.xfce-look.org/p/1203015/. There may be more, I didn't go through full list,.

Offline

#6 2019-09-23 01:50:38

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

is a theme in one file or more than one?  and where does it/they go?  being a command-line person, i've really never used a theme before.  i have no idea how it is done.  i assume xfce components look for specific files or specific references in their config files.  i'm guessing that individual users can download their own or the sysadmin can install many and there is a common place for that.

edit:

the user i want to put this theme on is super-restricted and can't run firefox or a terminal.  it won't be able to install the theme by itself.  so i will need to do any file installs from root on its behalf.

Last edited by Skaperen (2019-09-23 02:07:54)

Offline

#7 2019-09-23 02:11:59

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 5,886

Re: how to remove title bar from a non-terminal application?

Offline

#8 2019-09-23 03:53:41

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

is there a non-abusive way to download all the themes?  and, yes, my clock looks much better, now.

Last edited by Skaperen (2019-09-23 03:54:57)

Offline

#9 2019-09-23 03:59:52

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

Aravisian wrote:
Skaperen wrote:

is there a way to tell which themes minimize or remove the title bar?  making it black me be just as good.  if there is a way to make dclock go full screen an still use a 720 pixel high font, that would work.  the goal is to have as black a screen as possible with a very large red LED style digital clock on it.  just for that one user.

I could make a conky clock that does that. I know this by accident.

could you share the code and the fix?  i'm trying to learn GUI programming.  i've done programming in several languages for decades, mostly systems stuff, but never GUI or on Windows.

Offline

#10 2019-09-23 07:29:35

Aravisian
Member
Registered: 2019-08-17
Posts: 132

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

could you share the code and the fix?  i'm trying to learn GUI programming.  i've done programming in several languages for decades, mostly systems stuff, but never GUI or on Windows.

https://linux.die.net/man/1/conky

sudo apt-get install conky-all
sudo add-apt-repository ppa:mark-pcnetspec/conky-manager-pm9
sudo apt-get update
sudo apt-get install conky-manager

http://conky.sourceforge.net/docs.html

Really, the best way is to jump in and start playing with it.
Commands are straightfoward, use # to comment out, $ to note cmd.
Below I pasted my clock conky- it uses a background image that is not included in this thread... but no biggie, there. You can create one, if you like, that is totally black.
Colors, just use an html color picker of your choice. Black being #000000.
Under Minimum size just above alignment, you can increase the size as needed. Then where you see "${font <name of font>:size=__}" fill in the blank with the outrageously huge font size that works for you.
Originally, this conky operated at size 145 font and was offset and running in the background. I decided to tone it down and the spacing shows how it fits into the background image.
But you can adjust the spacing and placement as you see fit.
Install conky-all, then the conky manager. Open the manager and select your conky (Conky is placed in ~/.conky folder). While it is running, open the text editor file for that conky and make an adjustment, then hit save. The conky will immediately reload, reflecting the change. If your adjustment breaks it, the conky will vanish and not reappear. Just go back in and undo whatever you did, then restart the conky out of the manager.
I use Mousepad to open the file because it is very easy to undo a change. Gnomes text editor gedit- not so much.

#Conky settings
update_interval 1
total_run_times 0
net_avg_samples 1
cpu_avg_samples 1

#Text settings
use_xft yes
xftfont Droid Sans:pixelsize=16
override_utf8_locale no

#Window specifications
own_window yes
own_window_type override
own_window_transparent yes
own_window_colour 000000
own_window_argb_visual no
own_window_argb_value 0
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
background no
double_buffer yes
minimum_size 320 130

alignment top_middle
gap_x 0
gap_y 0

#Graphics settings
color1 85919e
color2 42a5f5
color3 19191a
color4 969696

TEXT
${image ./clock.png 0,0 -s 315x130}${alignr}${font D3Euronism:pixelsize=16}${color4}Chronometer       

  ${alignc}${font D3Euronism:pixelsize=55}${color2}${time %I}:${color1}${time %M}${alignc}${font D3Euronism:size=14}${color1} ${color2}${time %S}${color1}

Offline

#11 2019-09-23 23:05:40

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

here is my clock user screen.  i switch to this user when my laptop is not in use but i am in the same room, so i can quickly see what time it is without my glasses being on.

Offline

#12 2019-09-23 23:40:05

Aravisian
Member
Registered: 2019-08-17
Posts: 132

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

here is my clock user screen.  i switch to this user when my laptop is not in use but i am in the same room, so i can quickly see what time it is without my glasses being on.

At 720 font size, you have a bigger screen than I do. big_smile

Can you try this on for size?
You may need to change positioning, font, font size or color to suit...
Adjust the line "minimum size" to suit your screen in order to fill the entire screen as black background.

#Conky settings
update_interval 1
total_run_times 0
net_avg_samples 1
cpu_avg_samples 1

#Text settings
use_xft yes
xftfont Digital Readout Thick Upright:pixelsize=720
override_utf8_locale no

#Window specifications
own_window yes
own_window_type override
own_window_transparent no
own_window_argb_visual yes
own_window_argb_value 0,0,0
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager
background no
double_buffer yes
minimum_size 720 700

alignment middle_middle
gap_x 0
gap_y 0

#Graphics settings
color1 red


TEXT
${color1}${time %H}:${time %M}:${font Digital Readout Thick Upright:size=200}${time %S}${font}

The white bar blob you see at top of primary monitor is merely because my lousy butt is running two different sized monitors.
8qxSSsf.png

Last edited by Aravisian (2019-09-23 23:45:29)

Offline

#13 2019-09-24 22:47:55

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

i don't know how to try that code.  do i need to put it in a file and feed it to stdin on some program?

Offline

#14 2019-09-24 22:57:44

Aravisian
Member
Registered: 2019-08-17
Posts: 132

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

i don't know how to try that code.  do i need to put it in a file and feed it to stdin on some program?

Skaperen, it is a conky.
In post number 10, above, I gave the installation instructions, etc.
Conky is a background object that is visible on the desktop and runs in the bacckground, but does not interact. So you can operate GUI objects on your screen all you want without any conky interference.

The reason I suggested using it as a conky is because it is easy but also allows you to easily open and operate any other thing without the conky interacting with it in any way. It also runs very lightweight.

If you would like to try it out and use it, just follow the guide in post number ten.
This script I just posted in post 12; just copy and paste it using Mousepad or text editor. Save it as "conky_clock" if you like, or any wily name you prefer.  No file ext like "txt" or anything. Just the name.
Create your .conky folder in your home folder. Save the "conky_clock" script in the .conky folder.
If this was my computer and my problem to solve, this is how I would choose to solve it.

sudo apt-get install conky-all
sudo add-apt-repository ppa:mark-pcnetspec/conky-manager-pm9
sudo apt-get update
sudo apt-get install conky-manager

Once conky-all and conky manager are installed, open conky manager either with terminal or your apps menu.
The GUI will open and offer you the conky_clock
Checkbox it and it will begin to run.
At the top of the conky manager, you will see a settings icon- clicking the conky-clock listed in the gui to highlight it, then clicking settings will open a pop up that gives config options, including screen positioning.
The next icon over to the right will open the text editor for manually editing the conky text. You may neet to adjust minimum size or font or color or any other thing and can easily access it that way.
Hope this helps.

Last edited by Aravisian (2019-09-24 23:02:56)

Offline

#15 2019-09-24 23:01:01

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

Aravisian wrote:
Skaperen wrote:

here is my clock user screen.  i switch to this user when my laptop is not in use but i am in the same room, so i can quickly see what time it is without my glasses being on.

At 720 font size, you have a bigger screen than I do. big_smile

my screen is 1920x1080 (2K/HD).  i like to make full use of the space.  but in this case 720 avoided stretching the digits too much.

my intent is to get a 3840x2160 (4K/UHD) in a year or two.  i hope text mode will be at least semi-visible. i will need to double the font size in terminals.  well, maybe almost double and squeeze a few more rows of text into it.

Offline

#16 2019-09-24 23:39:34

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

when you first said "conky" it came across to me as an adjective as that is the only way i have used that word.  and, post #10 just flew over my head.  let my try things.

i installed it and saved ~/.conky/conky_clock.  so, now, how do i run this?  type in "conky"?  i tried that and got a little borderless monitor window behind the terminal.  it seems to be stuck on the root window and shows up in every workspace (i'm assuming because it is stuck to root).  but i see no clock.  when i click the mouse anywhere on the root that window vanishes but the command is still stuck in the foreground.  ^C kills it gracefully.

Last edited by Skaperen (2019-09-24 23:40:13)

Offline

#17 2019-09-25 02:39:00

Aravisian
Member
Registered: 2019-08-17
Posts: 132

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

when you first said "conky" it came across to me as an adjective as that is the only way i have used that word.  and, post #10 just flew over my head.  let my try things.

i installed it and saved ~/.conky/conky_clock.  so, now, how do i run this?  type in "conky"?  i tried that and got a little borderless monitor window behind the terminal.  it seems to be stuck on the root window and shows up in every workspace (i'm assuming because it is stuck to root).  but i see no clock.  when i click the mouse anywhere on the root that window vanishes but the command is still stuck in the foreground.  ^C kills it gracefully.

Glad you got it killed. And I didn't name the thing big_smile

After you

sudo apt-get install conky-manager

open the conky through Conky Manager as that will allow you the greatest control.
I am posting a screenshot (Switched to Aurora theme for visibility) to show what you should see:
TbRIyeh.png
in that list that shows ~/.conky, you should see the contents of your .conky folder. The checkbox next to it is ready to be checkmarked.
When you checkmark it, the conky should start running in the backgound.
To stop it, just uncheckmark it in the conky manager. In the top row of icons, there is also a Kill Switch for it.
On your conky manager, the fifth and sixth icons on the toolbar from the left are the Settings and the Open in Text Editor commands.

Offline

#18 2019-10-04 00:24:47

VertreterDerIndustrie
Member
Registered: 2019-10-03
Posts: 3

Re: how to remove title bar from a non-terminal application?

I'm using the following python script (I've found on the internet) to toggle window decorations for individual windows:

#!/usr/bin/python2
import gtk.gdk
rootwin = gtk.gdk.get_default_root_window()
activewin = gtk.gdk.window_foreign_new (rootwin.property_get("_NET_ACTIVE_WINDOW")[2][0])
activedeko = activewin.get_decorations()
activewin.set_decorations ((activedeko + 1) % 2)
gtk.gdk.window_process_all_updates()
gtk.gdk.flush()

You run this script (for example from the xfce-menu) and the currently focused window shows/hides it's border.

But there is a problem with xfce (only?): It won't work the first time for a (newly created) window. You have to run the script twice to remove the initial border decoration. Maybe a bug in xfce?

Offline

#19 2019-10-04 00:33:17

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

looks interesting.  i will give it a try.

Offline

#20 2019-10-04 00:39:39

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

that first run that does nothing takes extra time to run.  strange.  it did that on a window that had been there for hours.  i suspect the gtk code is doing something else that first time.  it should still toggle, anyway ... you'd think.  so it could still be a bug.

Offline

#21 2019-10-04 00:50:12

VertreterDerIndustrie
Member
Registered: 2019-10-03
Posts: 3

Re: how to remove title bar from a non-terminal application?

Skaperen wrote:

i suspect the gtk code is doing something else that first time.

the problem is: activewin.get_decorations() returns 0 on the first run, even if there is a window-decoration. I think this function refers to some X11 property that isn't correctly initialized by xfwm?

Then the first invocation of this script sets the property with activewin.set_decorations(1), so the next call will toggle it to zero.

Offline

#22 2019-10-04 04:52:27

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

i'm trying to make the script detect that situation.  if it always takes extra time in the very first action on that window, i can make the script detect that.  it would get time before and after, compute the delta, append this new delta to a file, read in all the deltas, find the median, and check if this new delta is greater than that median as the indication this is the first call for that window (very primitive learning).

Offline

#23 2019-10-04 05:07:08

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

dismiss the previous idea.

that long delay (about 2-3 seconds) is not happening any more.  i switched workspace to be sure it was a first time window but that did not have the delay.  i switched to a different user which would be a whole new instance of X and still no delay.  i'll check it the next time i reboot to see if it's python2 doing it.  i use python3, so python2 may have not been cached.

Offline

#24 2019-10-05 17:47:02

Skaperen
Member
From: surface of planet Earth
Registered: 2013-06-15
Posts: 441

Re: how to remove title bar from a non-terminal application?

i rebooted, so memory was empty of things like python2 and ran that script again. no delay.  i guess that first delay was a fluke event.

Offline

Board footer

Powered by FluxBB