1 /* gtkdocmarkupwriter.vala
3 * Copyright (C) 2012 Florian Brosch
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20 * Florian Brosch <flo.brosch@gmail.com>
25 public class Valadoc
.GtkDocMarkupWriter
: Valadoc
.MarkupWriter
{
26 private unowned StringBuilder builder
;
28 public void reset () {
35 public unowned
string content
{
36 get { return builder
.str
; }
39 public GtkDocMarkupWriter () {
40 StringBuilder builder
= new
StringBuilder ();
41 base ((str
) => { builder
.append (str
); }, false);
42 this
.builder
= builder
;
45 protected override bool inline_element (string name
) {
47 && name
!= "programlisting"
53 && name
!= "mediaobject"
54 && name
!= "imageobject"
55 && name
!= "textobject"
57 && name
!= "orderedlist"
58 && name
!= "itemizedlist"
62 protected override bool content_inline_element (string name
) {
64 || name
== "programlisting"
66 || name
== "blockquote"