Hi all,
ODF1.2 defines 15 standard symbols for charts. As earlier mentioned, I
try to implement the missing ones. But there are some problems with the
symbols "horizontal-bar" and "vertical-bar".
The implementation of the current symbols in
/calc/chart2/source/view/main/ShapeFactory.cxx in method
createPolyPolygon_Symbol draws the symbols in a way, that the given size
in parameter rSize is completely used. Moreover, this method is called
with a square in rSize in all default cases.
I have tried now this way for a "horizontal-bar": Draw a rectangle,
which is 1/5 of the given height. With this attempt I get correct
symbols in the chart itself and in the legend. But the preview in the
data series dialog or in the data point dialog paints my
"horizontal-bar" and my "vertical-bar" as square. And in the list in the
pop-up menu my bars are shifted.
As far as I see, the graphics to be used in the dialog are generated in
components/cui/source/tapages/tpline.cxx. My idea is now to insert a
100% transparent square into the temporary page pPage and mark that
object together with my symbols for generating the bitmaps.
For inserting an additional object, I have used
SdrObject *pInvisibleSquare=pSymbolList->GetObj(0);
pInvisibleSquare=pInvisibleSquare->Clone();
pPage->NbcInsertObject(pInvisibleSquare);
in IMPL_LINK( SvxLineTabPage, MenuCreateHdl_Impl, MenuButton *, pButton )
after line 1540 and
pView->MarkAll();
instead of
pView->MarkObj(pObj,pPageView);
in line 1552 seems to work too.
But I do not know how to make the object transparent. Especially, I do
not know how to use these "itempool"-thing. In Basic I would have
assigned a value to the property. But in C++ I'm totally lost. Do you
can point me to a guide or lead me to a solution?
Kind regards
Regina
Context
- [Libreoffice] How to set fillcolor and linecolor to a SdrObject? · Regina Henschel
Privacy Policy |
Impressum (Legal Info) |
Copyright information: Unless otherwise specified, all text and images
on this website are licensed under the
Creative Commons Attribution-Share Alike 3.0 License.
This does not include the source code of LibreOffice, which is
licensed under the Mozilla Public License (
MPLv2).
"LibreOffice" and "The Document Foundation" are
registered trademarks of their corresponding registered owners or are
in actual use as trademarks in one or more countries. Their respective
logos and icons are also subject to international copyright laws. Use
thereof is explained in our
trademark policy.