vclunohelper.cxx (b0724fc6) vclunohelper.cxx (45fd3b9a)
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 5 unchanged lines hidden (view full) ---

14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied. See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 5 unchanged lines hidden (view full) ---

14 * software distributed under the License is distributed on an
15 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16 * KIND, either express or implied. See the License for the
17 * specific language governing permissions and limitations
18 * under the License.
19 *
20 *************************************************************/
21
22
23
24// MARKER(update_precomp.py): autogen include statement, do not remove
25#include "precompiled_toolkit.hxx"
26
27#include <tools/debug.hxx>
28#include <tools/stream.hxx>
29#include <vcl/bitmap.hxx>
30#include <vcl/window.hxx>
31#include <com/sun/star/util/MeasureUnit.hpp>

--- 5 unchanged lines hidden (view full) ---

37#include <com/sun/star/awt/FontDescriptor.hpp>
38#include <com/sun/star/awt/XControlContainer.hpp>
39#include <com/sun/star/awt/FontWeight.hpp>
40#include <com/sun/star/awt/FontWidth.hpp>
41#include <com/sun/star/awt/KeyModifier.hpp>
42#include <com/sun/star/awt/MouseButton.hpp>
43#include <com/sun/star/lang/XMultiServiceFactory.hpp>
44#include <com/sun/star/embed/EmbedMapUnits.hpp>
22// MARKER(update_precomp.py): autogen include statement, do not remove
23#include "precompiled_toolkit.hxx"
24
25#include <tools/debug.hxx>
26#include <tools/stream.hxx>
27#include <vcl/bitmap.hxx>
28#include <vcl/window.hxx>
29#include <com/sun/star/util/MeasureUnit.hpp>

--- 5 unchanged lines hidden (view full) ---

35#include <com/sun/star/awt/FontDescriptor.hpp>
36#include <com/sun/star/awt/XControlContainer.hpp>
37#include <com/sun/star/awt/FontWeight.hpp>
38#include <com/sun/star/awt/FontWidth.hpp>
39#include <com/sun/star/awt/KeyModifier.hpp>
40#include <com/sun/star/awt/MouseButton.hpp>
41#include <com/sun/star/lang/XMultiServiceFactory.hpp>
42#include <com/sun/star/embed/EmbedMapUnits.hpp>
45
46#include <com/sun/star/graphic/XGraphic.hpp>
43#include <com/sun/star/graphic/XGraphic.hpp>
47
48#include <toolkit/helper/vclunohelper.hxx>
49#include <toolkit/helper/convert.hxx>
50#include <toolkit/awt/vclxbitmap.hxx>
51#include <toolkit/awt/vclxregion.hxx>
52#include <toolkit/awt/vclxwindow.hxx>
53#include <toolkit/awt/vclxgraphics.hxx>
54#include <toolkit/awt/vclxpointer.hxx>
55#include <toolkit/awt/vclxfont.hxx>
56#include <toolkit/controls/unocontrolcontainer.hxx>
57#include <toolkit/controls/unocontrolcontainermodel.hxx>
44#include <toolkit/helper/vclunohelper.hxx>
45#include <toolkit/helper/convert.hxx>
46#include <toolkit/awt/vclxbitmap.hxx>
47#include <toolkit/awt/vclxregion.hxx>
48#include <toolkit/awt/vclxwindow.hxx>
49#include <toolkit/awt/vclxgraphics.hxx>
50#include <toolkit/awt/vclxpointer.hxx>
51#include <toolkit/awt/vclxfont.hxx>
52#include <toolkit/controls/unocontrolcontainer.hxx>
53#include <toolkit/controls/unocontrolcontainermodel.hxx>
58
59#include <vcl/graph.hxx>
60#include <comphelper/processfactory.hxx>
54#include <vcl/graph.hxx>
55#include <comphelper/processfactory.hxx>
61
62#include <com/sun/star/awt/Size.hpp>
63#include <com/sun/star/awt/Point.hpp>
56#include <com/sun/star/awt/Size.hpp>
57#include <com/sun/star/awt/Point.hpp>
58#include <vcl/dibtools.hxx>
64
65using namespace ::com::sun::star;
66
67// ----------------------------------------------------
68// class VCLUnoHelper
69// ----------------------------------------------------
70
71::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit> VCLUnoHelper::CreateToolkit()

--- 24 unchanged lines hidden (view full) ---

96 if ( pVCLBitmap )
97 aBmp = pVCLBitmap->GetBitmap();
98 else
99 {
100 Bitmap aDIB, aMask;
101 {
102 ::com::sun::star::uno::Sequence<sal_Int8> aBytes = rxBitmap->getDIB();
103 SvMemoryStream aMem( (char*) aBytes.getArray(), aBytes.getLength(), STREAM_READ );
59
60using namespace ::com::sun::star;
61
62// ----------------------------------------------------
63// class VCLUnoHelper
64// ----------------------------------------------------
65
66::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit> VCLUnoHelper::CreateToolkit()

--- 24 unchanged lines hidden (view full) ---

91 if ( pVCLBitmap )
92 aBmp = pVCLBitmap->GetBitmap();
93 else
94 {
95 Bitmap aDIB, aMask;
96 {
97 ::com::sun::star::uno::Sequence<sal_Int8> aBytes = rxBitmap->getDIB();
98 SvMemoryStream aMem( (char*) aBytes.getArray(), aBytes.getLength(), STREAM_READ );
104 aMem >> aDIB;
99 ReadDIB(aDIB, aMem, true);
105 }
106 {
107 ::com::sun::star::uno::Sequence<sal_Int8> aBytes = rxBitmap->getMaskDIB();
108 SvMemoryStream aMem( (char*) aBytes.getArray(), aBytes.getLength(), STREAM_READ );
100 }
101 {
102 ::com::sun::star::uno::Sequence<sal_Int8> aBytes = rxBitmap->getMaskDIB();
103 SvMemoryStream aMem( (char*) aBytes.getArray(), aBytes.getLength(), STREAM_READ );
109 aMem >> aMask;
104 ReadDIB(aMask, aMem, true);
110 }
111 aBmp = BitmapEx( aDIB, aMask );
112 }
113 }
114 return aBmp;
115}
116
117::com::sun::star::uno::Reference< ::com::sun::star::awt::XBitmap> VCLUnoHelper::CreateBitmap( const BitmapEx& rBitmap )

--- 679 unchanged lines hidden ---
105 }
106 aBmp = BitmapEx( aDIB, aMask );
107 }
108 }
109 return aBmp;
110}
111
112::com::sun::star::uno::Reference< ::com::sun::star::awt::XBitmap> VCLUnoHelper::CreateBitmap( const BitmapEx& rBitmap )

--- 679 unchanged lines hidden ---