Author Topic: Grouping Libreoffice Writer windows leaving Calc alone?  (Read 2380 times)

Snap

  • Posts: 465
    • View Profile
Grouping Libreoffice Writer windows leaving Calc alone?
« on: October 05, 2015, 09:22:32 AM »
Coming from here.

I can group libreoffice windows now. But I don't want writer and calc windows grouped together. I want the spreadsheets to be left alone for my particular needs. Need to see and compare work schedules and road routes displayed at once side by side, so grouping spreadsheets is a drawback for me. But this code groups everything libreoffice together.

Code: [Select]
[group]  (workspace=[current])
 [app] (name=libreoffice) (class=libreoffice-writer)
[app] (name=libreoffice) (class=LibreOffice 5.0)
  [Position] (UPPERLEFT) {4% 3%}
  [Shaded] {no}
  [Deco] {NORMAL}
  [Sticky] {no}
  [Minimized] {no}
  [Maximized] {no}
  [Fullscreen] {no}
  [Layer] {8}
  [Alpha] {255}
[end]

Any ideas on how to proceed? This nasty line seems to gather everything together: [app] (name=libreoffice) (class=LibreOffice 5.0) but if I remove it the libreoffice grouping stops working at all.

PackRat

  • Posts: 1879
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #1 on: October 05, 2015, 01:14:27 PM »
You're going to have to try using something in addition to the Name and Class options provided by xprop - like Role or Title

man page fluxbox-apps

Code: [Select]
          Title
               A string, corresponding to the window title (WM_NAME from xprop(1)).

           Role
               A string, corresponding to the ROLE property (WM_WINDOW_ROLE from xprop(1)).

Editing the Fluxbox apps file
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

Snap

  • Posts: 465
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #2 on: October 06, 2015, 06:38:58 AM »
Yes, I know, but the problem is that xprop says nothing about window role in most apps. Some programs use that feature but most doesn't. It seems libreoffice doesn't. I wonder if there is a way to tweak that, like in conky where you can specify and set name, class, title or role at will. I'm afraid that's not posible or at least easy for common apps.

Since role doesn't seem to be an option for libreoffice, I guess I'll need to play with window names, titles and classes and see what i can get. Thanks anyway, PackRat. Your advice is always welcome.

Snap

  • Posts: 465
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #3 on: October 06, 2015, 07:08:17 AM »
No way. You cannot touch this line at all.

Code: [Select]
[app] (name=libreoffice) (class=LibreOffice 5.0)
LO grouping stops working at all. Tried to add bits like (title=.*LibreOffice Writer.*) to that line as an attempt to exclude Calc and it stops working every time. Inf act, that line alone does the job. Removing this other line

Code: [Select]
[app] (name=libreoffice) (class=libreoffice-writer)
proves it's irrelevant for LibreOffice 5. It can be deleted altogether. It used to work for LO4, but now it's different. It does nothing.

Unless there is way to exclude windows from a group I cannot figure out a solution. I'm afraid I'll have to disable that group whenever I need to deal with spreadsheets. Thankfully I only need them once or twice per month while I use the writer all the time.

Well, this is the very first real annoyance I find in Fluxbox. It's not that bad. But no major complains about fluxbox aside of this and wishing that piping things into menus would be easier.

PackRat

  • Posts: 1879
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #4 on: October 06, 2015, 11:33:59 AM »
Have you ever used wmctrl? 

That app may be able to help you out here. You may be able to set it up so that writer and calc windows open with unique titles. I'm not sure if it can be used to define a role for a window.
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

Snap

  • Posts: 465
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #5 on: October 07, 2015, 11:12:54 PM »
Yes, but never went very deep into it. It's the right time now. I need 48 hours days!  ::)

Thanks again.

PackRat

  • Posts: 1879
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #6 on: October 18, 2015, 01:34:53 PM »
This morning (18 Oct) I posted a question concerning this in the fluxbox group on google.

Patiently waiting .........  8)
I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

Snap

  • Posts: 465
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #7 on: October 19, 2015, 10:26:52 AM »
Thanks, RatMan.

let's smoke in the meanwhile.  8)

PackRat

  • Posts: 1879
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #8 on: December 03, 2015, 09:37:34 PM »
No action at the fluxbox google group. But I did find this in the "Client Patterns" of the fluxbox-apps man page (towards the end):

Code: [Select]
CLIENT PATTERNS
       A pattern looks like this
           ([propertyname[!]=]regexp) ...

< snip >

 @XPROP
       A string, corresponding to any xproperty (Use either the xprop(1) utility or the SetXProp command to set a xproperty to a window)

The way I understand that, you could use xprop to find a unique property to documents and spreadsheets and group accordingly, or use SetXProp to actually create unique client patterns and then group accordingly.

I am tired of talk that comes to nothing.
-- Chief Joseph

...the sun, the darkness, the winds are all listening to what we have to say.
-- Geronimo

Snap

  • Posts: 465
    • View Profile
Re: Grouping Libreoffice Writer windows leaving Calc alone?
« Reply #9 on: December 04, 2015, 10:31:17 AM »
Hey, thanks, PackRat! That sounds like a real solution. Time to experiment.