summaryrefslogtreecommitdiff
path: root/poppler-glib/src/layers_iter.hg
blob: 4080be494f1f9ecc6311144b458b849ffc118cfa (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/* Copyright (c) 2010  Glenn Rice <glennricster@gmail.com>
 *
 * This file is part of poppler-glibmm.
 *
 * poppler-glibmm is free software: you can redistribute it and/or modify it
 * under the terms of the GNU Lesser General Public License as published
 * by the Free Software Foundation, either version 2.1 of the License,
 * or (at your option) any later version.
 *
 * poppler-glibmm is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 * See the GNU Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

_DEFS(poppler-glibmm,poppler-glib)
#include <poppler-glibmm/layer.h>
_CC_INCLUDE(poppler.h)

namespace Poppler
{

/** Poppler::LayersIter is used to iterate through the layers of a document
 */
class LayersIter
{
  _CLASS_BOXEDTYPE(LayersIter, PopplerLayersIter, NONE, poppler_layers_iter_copy, poppler_layers_iter_free)
  _IGNORE(poppler_layers_iter_copy, poppler_layers_iter_free)

  public:
    _WRAP_METHOD(LayersIter get_child() const, poppler_layers_iter_get_child)
    _WRAP_METHOD(Glib::RefPtr<Layer> get_layer() const, poppler_layers_iter_get_layer)
    _WRAP_METHOD(Glib::ustring get_title() const, poppler_layers_iter_get_title)
    _WRAP_METHOD(bool next() const, poppler_layers_iter_next)

    /** Returns <tt>true</tt> if this LayersIter contains valid information
     * about layers in the associated document.
     * @return <tt>true</tt>, if the LayersIter is valid
     */
    inline operator bool() const { return gobj() != NULL; };
};

} // namespace Poppler