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 9 * with the License. You may obtain a copy of the License at 10 * 11 * http://www.apache.org/licenses/LICENSE-2.0 12 * 13 * Unless required by applicable law or agreed to in writing, 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 #ifndef _BASICRENDERABLE_HXX 24 #define _BASICRENDERABLE_HXX 25 26 #include "com/sun/star/view/XRenderable.hpp" 27 #include "cppuhelper/compbase1.hxx" 28 29 #include "vcl/print.hxx" 30 31 class IDEBaseWindow; 32 33 namespace basicide 34 { 35 class BasicRenderable : 36 public cppu::WeakComponentImplHelper1< com::sun::star::view::XRenderable >, 37 public vcl::PrinterOptionsHelper 38 { 39 IDEBaseWindow* mpWindow; 40 osl::Mutex maMutex; 41 42 Printer* getPrinter(); 43 public: 44 BasicRenderable( IDEBaseWindow* pWin ); 45 virtual ~BasicRenderable(); 46 47 // XRenderable 48 virtual sal_Int32 SAL_CALL getRendererCount ( 49 const com::sun::star::uno::Any& aSelection, 50 const com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue >& xOptions) 51 throw (com::sun::star::lang::IllegalArgumentException, com::sun::star::uno::RuntimeException); 52 53 virtual com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue> SAL_CALL getRenderer ( 54 sal_Int32 nRenderer, 55 const com::sun::star::uno::Any& rSelection, 56 const com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue>& rxOptions) 57 throw (com::sun::star::lang::IllegalArgumentException, com::sun::star::uno::RuntimeException); 58 59 virtual void SAL_CALL render ( 60 sal_Int32 nRenderer, 61 const com::sun::star::uno::Any& rSelection, 62 const com::sun::star::uno::Sequence<com::sun::star::beans::PropertyValue>& rxOptions) 63 throw (com::sun::star::lang::IllegalArgumentException, com::sun::star::uno::RuntimeException); 64 65 }; 66 67 } // namespace 68 69 #endif 70