Re: [qubes-users] Re: Libreoffice Calc windowsize is 1x1 cm ..

2020-06-03 Thread Dave
thanks for your research and the extra info about the cause of the issue!


On Saturday, 30 May 2020 00:29:52 UTC+2, Steve Coleman wrote:
>
> I loved the idea of the macros to manage the desktop in general as I would 
> really like to pin Qubes Manager to desktop 1 and not have it start on 
> whatever desktop the person last logged out from.  But that is obviously 
> fixable now.
>
> I did do a little digging into this LO window size issue just because I 
> wanted to understand what was actually happening. I have had several VMs 
> act up, but not all of them in the same way, so I dug deeper to see what 
> the differences might be.
>
> The answer is  that window size information is stored in the file: 
> .config/libreoffice/4/user/registrymodifications.xcu
>
> > grep 
> ooSetupFactoryWindowAttributes 
> .config/libreoffice/4/user/registrymodifications.xcu 
>
>
> This will give you several lines like:
>
>  oor:path="/org.openoffice.Setup/Office/Factories/org.openoffice.Setup:Factory['com.sun.star.sheet.
> *SpreadsheetDocument*']"> oor:op="fuse">*61,61,1807,982;5;38,56,1807,982;*
> 
>
> By opening any Libreoffice app you can navigate to see/edit the same 
> values from the Tools menu:
> Tools
>Advanced
>   click [Open Expert Configuration]
>  Search for: "ooSetupFactoryWindowAttributes"
> Then scroll right to see the values set for each component as a string 
> value, eg:  "*61,61,1807,982;5;38,56,1807,982;*"
>
> The window position values are specified as:
> x-pos,y-pos,*width,height ;* window-state *;* 
> maximized-x-pos,maximized-y-pos,maximized-width,maximized-height *;*
>
> In my VMs that were broken (two pixel window size) this file was missing 
> all but one ooSetupFactoryWindowAttributes line in this file, where as 
> there were many lines, one for each libraOffice app in the working VMs. As 
> a test, I cut-n-pasted the group of lines from a working VM into the broken 
> xcu file using gedit and saved, and tried again. Everything worked! The 
> window size problem was gone. So then I started looking more closely with 
> gedit and meld to watch what was changeing.
>
> As each LO app is run it adds its line to the xcu file with x-pos,y-pos,
> *2,2*,... as the default width,height values of only two pixels. Changing 
> those values to any valid set of Width,Height numbers will make the window 
> open with that predefined size. Upon exiting the app with any manually 
> adjusted size does not save that new value back to the xcu file. Its 
> width,height values are apparently read at the start and completely ignored 
> on exit, even though the xcu file will be rewritten with many other 
> modified values.  For instance if you open and manually resize the window 
> and then click maximize just before before exiting then the *0,0* for the 
> *maximized-width,maximized-height* will be updated to that new set of 
> values but the origional *width,height* values will remain unchanged. It 
> appears that manually editing these width,height values from 2,2 to 
> 'something more reasonable' is the only way to perminantly change them. 
>
> Steve.
>
>
>
>
>
>
> On Thu, May 28, 2020 at 3:27 PM > wrote:
>
>>
>>
>> Am Donnerstag, 28. Mai 2020 20:34:45 UTC+2 schrieb Dave:
>>>
>>> Ok thanks for the tip, i just tested you suggestion and it resizes the 
>>> window perfectly.
>>> Do you autostart devilspie2 at boot .. or how do you use it ..?
>>>
>>>
>>  I start it via .desktop file in .config/autostart.
>>
>> It really is a handy tool. I use it for other things like mapping domains 
>> to certain workspaces.
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "qubes-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to qubes...@googlegroups.com .
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/qubes-users/3e39d011-8d2b-474e-818a-ed0b6058ef40%40googlegroups.com
>>  
>> 
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/ab9acfc5-33b5-417f-a5b8-a2c1091d616f%40googlegroups.com.


Re: [qubes-users] Re: Libreoffice Calc windowsize is 1x1 cm ..

2020-05-29 Thread Steve Coleman
I loved the idea of the macros to manage the desktop in general as I would
really like to pin Qubes Manager to desktop 1 and not have it start on
whatever desktop the person last logged out from.  But that is obviously
fixable now.

I did do a little digging into this LO window size issue just because I
wanted to understand what was actually happening. I have had several VMs
act up, but not all of them in the same way, so I dug deeper to see what
the differences might be.

The answer is  that window size information is stored in the file:
.config/libreoffice/4/user/registrymodifications.xcu

> grep
ooSetupFactoryWindowAttributes
.config/libreoffice/4/user/registrymodifications.xcu


This will give you several lines like:

*61,61,1807,982;5;38,56,1807,982;*


By opening any Libreoffice app you can navigate to see/edit the same values
from the Tools menu:
Tools
   Advanced
  click [Open Expert Configuration]
 Search for: "ooSetupFactoryWindowAttributes"
Then scroll right to see the values set for each component as a string
value, eg:  "*61,61,1807,982;5;38,56,1807,982;*"

The window position values are specified as:
x-pos,y-pos,*width,height ;* window-state *;*
maximized-x-pos,maximized-y-pos,maximized-width,maximized-height *;*

In my VMs that were broken (two pixel window size) this file was missing
all but one ooSetupFactoryWindowAttributes line in this file, where as
there were many lines, one for each libraOffice app in the working VMs. As
a test, I cut-n-pasted the group of lines from a working VM into the broken
xcu file using gedit and saved, and tried again. Everything worked! The
window size problem was gone. So then I started looking more closely with
gedit and meld to watch what was changeing.

As each LO app is run it adds its line to the xcu file with x-pos,y-pos,
*2,2*,... as the default width,height values of only two pixels. Changing
those values to any valid set of Width,Height numbers will make the window
open with that predefined size. Upon exiting the app with any manually
adjusted size does not save that new value back to the xcu file. Its
width,height values are apparently read at the start and completely ignored
on exit, even though the xcu file will be rewritten with many other
modified values.  For instance if you open and manually resize the window
and then click maximize just before before exiting then the *0,0* for the
*maximized-width,maximized-height* will be updated to that new set of
values but the origional *width,height* values will remain unchanged. It
appears that manually editing these width,height values from 2,2 to
'something more reasonable' is the only way to perminantly change them.

Steve.






On Thu, May 28, 2020 at 3:27 PM  wrote:

>
>
> Am Donnerstag, 28. Mai 2020 20:34:45 UTC+2 schrieb Dave:
>>
>> Ok thanks for the tip, i just tested you suggestion and it resizes the
>> window perfectly.
>> Do you autostart devilspie2 at boot .. or how do you use it ..?
>>
>>
>  I start it via .desktop file in .config/autostart.
>
> It really is a handy tool. I use it for other things like mapping domains
> to certain workspaces.
>
> --
> You received this message because you are subscribed to the Google Groups
> "qubes-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to qubes-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/qubes-users/3e39d011-8d2b-474e-818a-ed0b6058ef40%40googlegroups.com
> 
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/CAJ5FDnj7Z%3DcL%2BCA3RO2DfRWjpd%3DvKDr3N618uNmVmUVKpXHfYA%40mail.gmail.com.


[qubes-users] Re: Libreoffice Calc windowsize is 1x1 cm ..

2020-05-28 Thread palette999


Am Donnerstag, 28. Mai 2020 20:34:45 UTC+2 schrieb Dave:
>
> Ok thanks for the tip, i just tested you suggestion and it resizes the 
> window perfectly.
> Do you autostart devilspie2 at boot .. or how do you use it ..?
>
>
 I start it via .desktop file in .config/autostart.

It really is a handy tool. I use it for other things like mapping domains 
to certain workspaces.

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/3e39d011-8d2b-474e-818a-ed0b6058ef40%40googlegroups.com.


[qubes-users] Re: Libreoffice Calc windowsize is 1x1 cm ..

2020-05-28 Thread Dave
Ok thanks for the tip, i just tested you suggestion and it resizes the 
window perfectly.
Do you autostart devilspie2 at boot .. or how do you use it ..?

On Thursday, 28 May 2020 18:11:14 UTC+2, palet...@gmail.com wrote:
>
>
>
> Am Montag, 25. Mai 2020 21:19:03 UTC+2 schrieb Dave:
>>
>> When i open libreoffice Calc in my work vm, the only thing i can see of 
>> the window is the "X" mark of the window.
>> So the window opens up like 1x1cm.. When i drag it bigger to a normal 
>> window size and restart calc, its back to a little 1x1 cm box and just 
>> showing the close window 'X'..
>> How can i get calc to open up normal window size ..?
>>
>
> I had the same problem. I used devilspie2 to solve it.
>
> Install it to dom0:
> sudo qubes-dom0-update devilspie2
>
> then create a .lua file in .config/devilspie2 with the following text:
>
> window = "LibreOffice";
> windowname = get_window_name();
> if (string.match(windowname, window)) then
> maximize();
> end
>  
> Here is a nice tutorial about devilspie2, if you are interested: 
> https://www.linux-magazine.com/Issues/2017/205/Tutorial-Devilspie2
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/f40af9ee-3b1c-4e6d-a1ff-bfa9e0619662%40googlegroups.com.


[qubes-users] Re: Libreoffice Calc windowsize is 1x1 cm ..

2020-05-28 Thread palette999


Am Montag, 25. Mai 2020 21:19:03 UTC+2 schrieb Dave:
>
> When i open libreoffice Calc in my work vm, the only thing i can see of 
> the window is the "X" mark of the window.
> So the window opens up like 1x1cm.. When i drag it bigger to a normal 
> window size and restart calc, its back to a little 1x1 cm box and just 
> showing the close window 'X'..
> How can i get calc to open up normal window size ..?
>

I had the same problem. I used devilspie2 to solve it.

Install it to dom0:
sudo qubes-dom0-update devilspie2

then create a .lua file in .config/devilspie2 with the following text:

window = "LibreOffice";
windowname = get_window_name();
if (string.match(windowname, window)) then
maximize();
end
 
Here is a nice tutorial about devilspie2, if you are interested: 
https://www.linux-magazine.com/Issues/2017/205/Tutorial-Devilspie2

-- 
You received this message because you are subscribed to the Google Groups 
"qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to qubes-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/qubes-users/d9ba993c-f46c-4f0f-86c1-f82232ceacaf%40googlegroups.com.