vcl: allow for overriding the default PDF rendering resolution
[LibreOffice.git] / chart2 / source / controller / dialogs / res_BarGeometry.cxx
blob6b0a7eac220861b72c532b221f8f4e8c49cb054a
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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 #include <res_BarGeometry.hxx>
21 #include <ResId.hxx>
22 #include <chart.hrc>
24 namespace chart
27 BarGeometryResources::BarGeometryResources(weld::Builder* pBuilder)
28 : m_xFT_Geometry(pBuilder->weld_label("shapeft"))
29 , m_xLB_Geometry(pBuilder->weld_tree_view("shape"))
31 for (size_t i = 0; i < SAL_N_ELEMENTS(CHART_TYPE); ++i)
32 m_xLB_Geometry->append_text(SchResId(CHART_TYPE[i]));
33 m_xLB_Geometry->set_size_request(-1, m_xLB_Geometry->get_height_rows(4));
36 void BarGeometryResources::connect_changed(const Link<weld::TreeView&,void>& rLink)
38 m_xLB_Geometry->connect_changed(rLink);
41 void BarGeometryResources::set_visible( bool bShow )
43 m_xFT_Geometry->set_visible( bShow );
44 m_xLB_Geometry->set_visible( bShow );
47 void BarGeometryResources::set_sensitive( bool bEnable )
49 m_xFT_Geometry->set_sensitive( bEnable );
50 m_xLB_Geometry->set_sensitive( bEnable );
53 sal_Int32 BarGeometryResources::get_selected_index() const
55 return m_xLB_Geometry->get_selected_index();
58 void BarGeometryResources::select(sal_Int32 nPos)
60 if (nPos < m_xLB_Geometry->n_children())
61 m_xLB_Geometry->select(nPos);
64 } //namespace chart
66 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */