Presentation Settings

From Apache OpenOffice Wiki
Jump to: navigation, search

Impress documents contain a Presentation service that controls a running presentation. This service can be accessed through the interface through the method:

  com::sun::star::presentation::XPresentation getPresentation()

The method getPresentation() returns a service. It contains properties for presentation settings and the interface

The presentation settings define the slide range, which custom show is used, and how the presentation is executed. These settings are provided as properties of the service This service also exports the interface that starts and ends a presentation.

Methods of
start() Starts the presentation in full-screen mode.
end() Stops the presentation.
rehearseTimings() Starts the presentation from the beginning and shows the actual running time to the user.

Properties of
AllowAnimations boolean - Enables/disables the shape animations.
CustomShow string - Contains the name of a customized show that is used for the presentation.
Presentation:FirstPage string - Contains the name of the page where the presentation is started.
IsAlwaysOnTop boolean - If true, the window of the presentation is always on top of all the other windows.
IsAutomatic boolean - If true, all pages are changed automatically.
IsEndless boolean - If true, the presentation is repeated endlessly.
IsFullScreen boolean - If true, the presentation runs in full-screen mode.
IsLivePresentation boolean - With this property, the presentation is set to live mode.
IsMouseVisible boolean - If true, the mouse is visible during the presentation.
Pause long - Duration of the black screen after the presentation has finished.
StartWithNavigator boolean - If true, the Navigator is opened at the start of the presentation.
UsePen boolean - If true, a pen is shown during presentation.
IsShowAll boolean - Show all slides.
IsShowLogo boolean - Show Apache OpenOffice logo on pause page in automatic mode.
IsTransitionOnClick boolean - Slide change on mouse click, in addition to pressing cursor right.

The properties IsShowAll, IsShowLogo and IsTransitionOnClick are currently not documented in the API reference.

The next example demonstrates how to start a presentation that is automatically repeated and plays in full-screen mode by modifying the presentation settings.

  XPresentationSupplier xPresSupplier = (XPresentationSupplier)UnoRuntime.queryInterface( 
      XPresentationSupplier.class, xComponent);
  XPresentation xPresentation = xPresSupplier.getPresentation();
  XPropertySet xPresPropSet = (XPropertySet)UnoRuntime.queryInterface(
      XPropertySet.class, xPresentation);
  xPresPropSet.setPropertyValue("IsEndless", Boolean.TRUE);
  xPresPropSet.setPropertyValue("IsFullScreen", Boolean.TRUE);
  xPresPropSet.setPropertyValue("Pause", new Integer(0));
Content on this page is licensed under the Public Documentation License (PDL).
Personal tools
In other languages