Line data Source code
1 : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : /*
3 : * This file is part of the LibreOffice project.
4 : *
5 : * This Source Code Form is subject to the terms of the Mozilla Public
6 : * License, v. 2.0. If a copy of the MPL was not distributed with this
7 : * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 : */
9 :
10 : #include "ogl_canvasfont.hxx"
11 : #include "ogl_textlayout.hxx"
12 :
13 : #include <com/sun/star/rendering/XSpriteCanvas.hpp>
14 : #include <com/sun/star/rendering/PanoseWeight.hpp>
15 :
16 :
17 : using namespace ::com::sun::star;
18 :
19 : namespace oglcanvas
20 : {
21 0 : CanvasFont::CanvasFont( const rendering::FontRequest& rFontRequest,
22 : const uno::Sequence< beans::PropertyValue >& /*extraFontProperties*/,
23 : const geometry::Matrix2D& fontMatrix ) :
24 : CanvasFontBaseT( m_aMutex ),
25 : maFontRequest( rFontRequest ),
26 0 : maFontMatrix( fontMatrix )
27 : {
28 0 : }
29 :
30 0 : void SAL_CALL CanvasFont::disposing()
31 : {
32 0 : ::osl::MutexGuard aGuard( m_aMutex );
33 0 : }
34 :
35 0 : uno::Reference< rendering::XTextLayout > SAL_CALL CanvasFont::createTextLayout( const rendering::StringContext& aText,
36 : sal_Int8 nDirection,
37 : sal_Int64 nRandomSeed ) throw (uno::RuntimeException, std::exception)
38 : {
39 0 : ::osl::MutexGuard aGuard( m_aMutex );
40 :
41 0 : return new TextLayout( aText, nDirection, nRandomSeed, ImplRef( this ) );
42 : }
43 :
44 0 : uno::Sequence< double > SAL_CALL CanvasFont::getAvailableSizes( ) throw (uno::RuntimeException, std::exception)
45 : {
46 0 : ::osl::MutexGuard aGuard( m_aMutex );
47 :
48 : // TODO
49 0 : return uno::Sequence< double >();
50 : }
51 :
52 0 : uno::Sequence< beans::PropertyValue > SAL_CALL CanvasFont::getExtraFontProperties( ) throw (uno::RuntimeException, std::exception)
53 : {
54 0 : ::osl::MutexGuard aGuard( m_aMutex );
55 :
56 : // TODO
57 0 : return uno::Sequence< beans::PropertyValue >();
58 : }
59 :
60 0 : rendering::FontRequest SAL_CALL CanvasFont::getFontRequest( ) throw (uno::RuntimeException, std::exception)
61 : {
62 0 : ::osl::MutexGuard aGuard( m_aMutex );
63 :
64 0 : return maFontRequest;
65 : }
66 :
67 0 : rendering::FontMetrics SAL_CALL CanvasFont::getFontMetrics( ) throw (uno::RuntimeException, std::exception)
68 : {
69 0 : ::osl::MutexGuard aGuard( m_aMutex );
70 :
71 : // TODO
72 0 : return rendering::FontMetrics();
73 : }
74 :
75 : }
76 :
77 : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|