1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 module com
{ module sun
{ module star
{ module presentation
{
22 /** View interface to display slide show presentations on.<p>
24 This interface provides the necessary methods to enable an
25 XSlideShow interface to display a presentation. The slide show can
26 be displayed simultaneously on multiple views<p>
30 interface XSlideShowView
: ::com
::sun
::star
::uno
::XInterface
32 /** Get view canvas.<p>
34 This method gets the underlying XCanvas to display on this
37 @return XSpriteCanvas to display on. Must be valid, and the
38 same object, as long as this view is added to any slide show.
40 ::com
::sun
::star
::rendering
::XSpriteCanvas getCanvas
();
42 /** This method clears the whole view area.
44 The slide show uses this method to fully erase the view
45 content. Since the slide show has no notion of view size, this
46 is the only reliable way to wholly clear the view.
50 /** Query the current transformation matrix for this view.<p>
52 This method returns the transformation matrix of the
53 view. When notified via the transformation change listener,
54 the show will be displayed using the new transformation.<p>
56 @return the view transformation matrix. Note that the slide
57 show itself will paint all slides as one-by-one boxes, one
58 therefore has to at least provide a scaling at this matrix to
59 blow this up to the desired device pixel size (640 times 480,
60 or whatever size the output view has). Furthermore, the aspect
61 ratio of the scaling should match that of the slides
62 (otherwise, the slides will be scaled anisotropically).
64 ::com
::sun
::star
::geometry
::AffineMatrix2D getTransformation
();
66 /** Query the current translation offset used to fill the physical screen while keeping aspect ratio.<p>
68 This method returns the translation offset of the view of the
71 @return the slideshowview will be transformed in order to fill
72 the physical screen while keeping the aspect ratio.
73 In order to do so, we need to add a black border on the side. This method
74 return an IntegerSize2D which represent (x, y) translation.
75 x represents the width of the border on the left, for example.
77 ::com
::sun
::star
::geometry
::IntegerSize2D getTranslationOffset
();
79 /** Add a listener to get notified when the transformation matrix changes.<p>
81 This method registers a listener with the view, which will get
82 called every time the transformation matrix changes.<p>
85 Listener interface to call when the transformation matrix changes.
87 void addTransformationChangedListener
( [in] ::com
::sun
::star
::util
::XModifyListener xListener
);
89 /** Revoke a previously registered transformation matrix change listener.<p>
92 Listener interface to revoke from being called.
94 void removeTransformationChangedListener
( [in] ::com
::sun
::star
::util
::XModifyListener xListener
);
96 /** Add a listener to get notified when this view needs a repaint.<p>
98 This method registers a listener with the view, which will get
99 called every time the view needs an update of their screen
103 Listener interface to call when the view needs a repaint.
105 void addPaintListener
( [in] ::com
::sun
::star
::awt
::XPaintListener xListener
);
107 /** Revoke a previously registered paint listener.<p>
110 Listener interface to revoke from being called.
112 void removePaintListener
( [in] ::com
::sun
::star
::awt
::XPaintListener xListener
);
114 /** Add a mouse listener to the view.<p>
116 This method registers a listener with the view, which will get
117 called every time the mouse is clicked on the view.<p>
120 Listener interface to call when the mouse is clicked on the view.
122 void addMouseListener
( [in] com
::sun
::star
::awt
::XMouseListener xListener
);
124 /** Revoke a previously registered mouse listener.<p>
127 Listener interface to revoke from being called.
129 void removeMouseListener
( [in] com
::sun
::star
::awt
::XMouseListener xListener
);
131 /** Add a mouse motion listener to the view.<p>
133 This method registers a listener with the view, which will get
134 called every time the mouse is moved on the view.<p>
137 Listener interface to call when the mouse is moved on the view.
139 void addMouseMotionListener
( [in] com
::sun
::star
::awt
::XMouseMotionListener xListener
);
141 /** Revoke a previously registered mouse move listener.<p>
144 Listener interface to revoke from being called.
146 void removeMouseMotionListener
( [in] com
::sun
::star
::awt
::XMouseMotionListener xListener
);
148 /** Change the mouse cursor currently in effect.<p>
150 This method changes the mouse cursor currently in effect, for
154 New mouse cursor shape to display for this view. Must be from
155 the ::com::sun::star::awt::SystemPointer constant group.
157 void setMouseCursor
( [in] short nPointerShape
);
159 /** Get rectangle defining area inside of canvas device which
160 this slide show view uses.
162 ::com
::sun
::star
::awt
::Rectangle getCanvasArea
();
168 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */