Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-11-05 Thread Thorsten Behrens
Caolan McNamara wrote:
> I rather prefer loosing the ideal msoffice-alike gradient vs these odd
> extra dots though.
> 
No leg to stand on wrt. this bug any longer - but ideally of course,
one could fix both cases. :)

My thinking was, that an empty polygon really should not result in
*any* visible ink marks anywhere. Or do I miss something?

Cheers,

-- Thorsten


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-11-05 Thread Caolán McNamara
On Sat, 2014-08-23 at 00:01 +0200, Thorsten Behrens wrote:
> Regina Henschel wrote:
> > What is wrong with gradient fill and mso? Do you know an issue or do
> > you have test documents? I see no difference between AOO (without
> > the points) and LibreOffice (with this points).
> > 
> This blog should give some more background info; no bugdocs at hand
> currently, but shouldn't be hard to come by - the sticking point are
> the subshapes, e.g. the eyes of the smiley:
> 
>  
> http://blog.thebehrens.net/2009/07/21/selected-interop-improvement-how-to-fill-ppt-autoshapes/

So I updated the bug with a patch that reverts the adding of the dummy
polygons, which fixes the extra dots issue. But I also added an
example .pptx with a smiley face example which will render a little
different in the eyes afterwards.

I rather prefer loosing the ideal msoffice-alike gradient vs these odd
extra dots though.

C.

___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-08-22 Thread Thorsten Behrens
Regina Henschel wrote:
> What is wrong with gradient fill and mso? Do you know an issue or do
> you have test documents? I see no difference between AOO (without
> the points) and LibreOffice (with this points).
> 
This blog should give some more background info; no bugdocs at hand
currently, but shouldn't be hard to come by - the sticking point are
the subshapes, e.g. the eyes of the smiley:

 
http://blog.thebehrens.net/2009/07/21/selected-interop-improvement-how-to-fill-ppt-autoshapes/

HTH,

-- Thorsten


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-08-22 Thread Regina Henschel

Hi Thorsten,

Thorsten Behrens schrieb:

Regina Henschel wrote:

I think, the code that adds these points is

 if( !bLineGeometryNeededOnly )
1906 {
1907 // hack aNewB2DPolyPolygon to fill logic rect - this is
1908 // needed to produce gradient fills that look like mso
1909 aNewB2DPolygon.clear();
1910 aNewB2DPolygon.append(basegfx::B2DPoint(0,0));
1911 aNewB2DPolygon.setClosed(true);
1912 aNewB2DPolyPolygon.append(aNewB2DPolygon);
1913
1914 aNewB2DPolygon.clear();
1915
aNewB2DPolygon.append(basegfx::B2DPoint(aLogicRect.GetWidth(),
1916 aLogicRect.GetHeight()));
1917 aNewB2DPolygon.setClosed(true);
1918 aNewB2DPolyPolygon.append(aNewB2DPolygon);
1919 }

in core/svx/source/customshapes/EnhancedCustomShape2d.cxx


Yep, and see the comment why this is there.


What is wrong with gradient fill and mso? Do you know an issue or do you 
have test documents? I see no difference between AOO (without the 
points) and LibreOffice (with this points).


Kind regards
Regina
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-08-20 Thread Thorsten Behrens
Regina Henschel wrote:
> I think, the code that adds these points is
> 
> if( !bLineGeometryNeededOnly )
>1906 {
>1907 // hack aNewB2DPolyPolygon to fill logic rect - this is
>1908 // needed to produce gradient fills that look like mso
>1909 aNewB2DPolygon.clear();
>1910 aNewB2DPolygon.append(basegfx::B2DPoint(0,0));
>1911 aNewB2DPolygon.setClosed(true);
>1912 aNewB2DPolyPolygon.append(aNewB2DPolygon);
>1913
>1914 aNewB2DPolygon.clear();
>1915
> aNewB2DPolygon.append(basegfx::B2DPoint(aLogicRect.GetWidth(),
>1916 aLogicRect.GetHeight()));
>1917 aNewB2DPolygon.setClosed(true);
>1918 aNewB2DPolyPolygon.append(aNewB2DPolygon);
>1919 }
> 
> in core/svx/source/customshapes/EnhancedCustomShape2d.cxx
> 
Yep, and see the comment why this is there. It should _in theory_ be
trivial to filter out those empty polygons during pdf export, just
that (last time I tried), layers above miraculously split things up in
a funny way already.

First port of call for that these days would be the vcl metafile
processor in drawinglayer I guess.

P.S.: please Cc me for prompt answers. Too many lists. ;)

Cheers,

-- Thorsten


signature.asc
Description: Digital signature
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-08-19 Thread Regina Henschel

Regina Henschel schrieb:


I have currently now build to verify my assumption.


I have currently no build to verify my assumption.
--^

Kind regards
Regina
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-08-19 Thread Regina Henschel

Regina Henschel schrieb:

Hi Papamatti,

you mean https://bugs.freedesktop.org/show_bug.cgi?id=37559 ?

Papamatti schrieb:

Hello list,

I investigate the problem of two pixels (top left and bottom right)
around predefined shapes (circle, smiley, ellipse...)


Do you want to fix it?


I think, the code that adds these points is

if( !bLineGeometryNeededOnly )
   1906 {
   1907 // hack aNewB2DPolyPolygon to fill logic rect - this is
   1908 // needed to produce gradient fills that look like mso
   1909 aNewB2DPolygon.clear();
   1910 aNewB2DPolygon.append(basegfx::B2DPoint(0,0));
   1911 aNewB2DPolygon.setClosed(true);
   1912 aNewB2DPolyPolygon.append(aNewB2DPolygon);
   1913
   1914 aNewB2DPolygon.clear();
   1915 
aNewB2DPolygon.append(basegfx::B2DPoint(aLogicRect.GetWidth(),
   1916 
aLogicRect.GetHeight()));

   1917 aNewB2DPolygon.setClosed(true);
   1918 aNewB2DPolyPolygon.append(aNewB2DPolygon);
   1919 }

in core/svx/source/customshapes/EnhancedCustomShape2d.cxx

I have currently now build to verify my assumption.

Kind regards
Regina


___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Re: Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-08-19 Thread Regina Henschel

Hi Papamatti,

you mean https://bugs.freedesktop.org/show_bug.cgi?id=37559 ?

Papamatti schrieb:

Hello list,

I investigate the problem of two pixels (top left and bottom right)
around predefined shapes (circle, smiley, ellipse...)


Do you want to fix it?



You can reproduce the bug by
- Open LibreOffice Draw
- Draw a ellipse or circle


from the shape category "custom shape".


- Select your object and convert it to a polygon
- change into the edit points mode
- now you can see the additional point top left and bottom right.


I have used "Pentagon" and have got these additional points too. My 
first thought was, that it is something special for the MS-types, but 
the error remains, when I change to draw:type="non-primitive".




You can move these dots around, delete them and so on. Unfortunalely
they are visible on export into pdf or any other format.

This Bug does not exist in OOO3.20 and was fixed in AOO3.40.
It was Introduces during the development of OOo 3.30 and found it's way
during the fork into LibreOffice 3.3. This is the story so far.


Do you know a related issue or commit or cws from that time?



I investigate the files, which OOo 3.20 and LO4.2.4 are creating with
the steps described above and with an simple ellipse.

OpenOffice 3.20 has created this structure:
(There are no additional dots, and, surprise if i open this file with
LO4.2.4 and save it into another file and reopen it with LO4.2.4 the bug
is not present! Conclusion: The bug has something to do with the
creation of these shapes!)


   
 
   

  

  



That is a different kind of shape. Notice draw:ellipse instead of 
draw:custom-shape.





LibreOffice 4.2.4 (Ubuntu 14.04) creates this structure after drawing a
ellipse:


   
 
   
 
 
   
 
   


LibreOffice 4.2.4 (Ubuntu 14.04) creates this structure after convert
the ellipse into a polygon:
(But instead of a polygon, LO creates a path!!!)


   
 
   
 
   
 
   


After deleting the two additional dots and save the file again it
changed to a polygon!!!:
(Also look at the svg width, hight and the svg:viewBox) ;-)


If you make your tests with "Pentagon", it is easier to reconstruct the 
conversion.





   
 
   
 
   
 
   



After conversion it has only straight path segments, and after removing 
'M0 0zM2001 2001z' it is only one closed path. Therefore there is no 
need for the complex handling using a svd:d attribute, but a simple list 
of points is sufficient.


[..]

The two additional points should not be there. But I guess they were 
introduced to solve another problem. (Read related discussion in 
https://issues.apache.org/ooo/show_bug.cgi?id=37213 and 
https://issues.apache.org/ooo/show_bug.cgi?id=124084#c10.) Perhaps 
Thorsten remembers the reason and why they are not Apache OpenOffice.


Kind regards
Regina



___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice


Discussion of Bug 37759 - Pixel around Objects like ellipse

2014-08-19 Thread Papamatti
Hello list,

I investigate the problem of two pixels (top left and bottom right)
around predefined shapes (circle, smiley, ellipse...)

You can reproduce the bug by
- Open LibreOffice Draw
- Draw a ellipse or circle
- Select your object and convert it to a polygon
- change into the edit points mode
- now you can see the additional point top left and bottom right.

You can move these dots around, delete them and so on. Unfortunalely
they are visible on export into pdf or any other format.

This Bug does not exist in OOO3.20 and was fixed in AOO3.40.
It was Introduces during the development of OOo 3.30 and found it's way
during the fork into LibreOffice 3.3. This is the story so far.

I investigate the files, which OOo 3.20 and LO4.2.4 are creating with
the steps described above and with an simple ellipse.

OpenOffice 3.20 has created this structure:
(There are no additional dots, and, surprise if i open this file with
LO4.2.4 and save it into another file and reopen it with LO4.2.4 the bug
is not present! Conclusion: The bug has something to do with the
creation of these shapes!)


  

  
   
 
   
 



LibreOffice 4.2.4 (Ubuntu 14.04) creates this structure after drawing a
ellipse:


  

  


  

  


LibreOffice 4.2.4 (Ubuntu 14.04) creates this structure after convert
the ellipse into a polygon:
(But instead of a polygon, LO creates a path!!!)


  

  

  

  


After deleting the two additional dots and save the file again it
changed to a polygon!!!:
(Also look at the svg width, hight and the svg:viewBox) ;-)


  

  

  

  


Alternatively I create this file, instead of deleting the two dots I
move them slightly away from the object. The result is:


  

  

  

  


Very strange.
___
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice