def to_html(self):
        """Print HTML version of theme."""
        self.html_nick_self = 'mario'
        channel = '#weechat'
        oldtopic = 'Welcome'
        newtopic = 'Welcome to %s - help channel for WeeChat' % channel
        nicks = ('@carl', '@jessika', '@louise', '%Melody', '%Diego', '+Max',
                 'sheryl', 'Harold^', 'richard', 'celia', 'Eva', 'freddy', 'lee',
                 'madeleine', self.html_nick_self, 'mila', 'peter', 'tina', 'Vince', 'warren', 'warren2')
        nicks_hosts = ('test@foo.com', 'something@host.com')
        chat_msgs = ('Hello!',
                     'hi mario, I just tested your patch',
                     'I would like to ask something',
                     'just ask!',
                     'WeeChat is great?',
                     'yes',
                     'indeed',
                     'sure',
                     'of course!',
                     'affirmative',
                     'all right',
                     'obviously...',
                     'certainly!')
        html = []
        #html.append('<pre style="line-height: 1.2em">')
        html.append('<pre>')
        width = self.chat_width + 1 + self.nicklist_width

        # title bar
        html.append(self.html_string(newtopic, width,
                                     'weechat.bar.title.color_fg', 'weechat.bar.title.color_bg'))

        # chat
        chat = []
        str_prefix_join = self.html_string('-->', self.prefix_width * -1, 'weechat.color.chat_prefix_join', 'weechat.color.chat_bg')
        str_prefix_quit = self.html_string('<--', self.prefix_width * -1, 'weechat.color.chat_prefix_quit', 'weechat.color.chat_bg')
        str_prefix_network = self.html_string('--', self.prefix_width * -1, 'weechat.color.chat_prefix_network', 'weechat.color.chat_bg')
        str_prefix_empty = self.html_string('', self.prefix_width * -1, 'weechat.color.chat', 'weechat.color.chat_bg')
        chat.append(self.html_chat((9, 10, 00),
                                   str_prefix_join,
                                   (('', self.html_nick_self),
                                    ('weechat.color.chat_delimiters', ' ('),
                                    ('weechat.color.chat_host',       nicks_hosts[0]),
                                    ('weechat.color.chat_delimiters', ')'),
                                    ('irc.color.message_join',        ' has joined '),
                                    ('weechat.color.chat_channel',    channel))))
        chat.append(self.html_chat((9, 10, 25),
                                   self.html_nick(nicks, 8, True, True, False, self.prefix_width * -1),
                                   (('weechat.color.chat', chat_msgs[0]),)))
        chat.append(self.html_chat((9, 11, 2),
                                   str_prefix_network,
                                   (('', nicks[0]),
                                    ('weechat.color.chat',         ' has changed topic for '),
                                    ('weechat.color.chat_channel', channel),
                                    ('weechat.color.chat',         ' from "'),
                                    ('irc.color.topic_old',        oldtopic),
                                    ('weechat.color.chat',         '"'))))
        chat.append(self.html_chat((9, 11, 2),
                                   str_prefix_empty,
                                   (('weechat.color.chat',  'to "'),
                                    ('irc.color.topic_new', newtopic),
                                    ('weechat.color.chat',  '"'))))
        chat.append(self.html_chat((9, 11, 36),
                                   self.html_nick(nicks, 16, True, True, True, self.prefix_width * -1),
                                   (('weechat.color.chat', chat_msgs[1]),)))
        chat.append(self.html_chat((9, 12, 4),
                                   str_prefix_quit,
                                   (('', 'joe'),
                                    ('weechat.color.chat_delimiters', ' ('),
                                    ('weechat.color.chat_host',       nicks_hosts[1]),
                                    ('weechat.color.chat_delimiters', ')'),
                                    ('irc.color.message_quit',        ' has left '),
                                    ('weechat.color.chat_channel',    channel),
                                    ('weechat.color.chat_delimiters', ' ('),
                                    ('irc.color.reason_quit',         'bye!'),
                                    ('weechat.color.chat_delimiters', ')'))))
        chat.append(self.html_chat((9, 15, 58),
                                   self.html_nick(nicks, 12, True, True, False, self.prefix_width * -1),
                                   (('weechat.color.chat', chat_msgs[2]),)))
        chat.append(self.html_chat((9, 16, 12),
                                   self.html_nick(nicks, 0, True, True, False, self.prefix_width * -1),
                                   (('weechat.color.chat', chat_msgs[3]),)))
        chat.append(self.html_chat((9, 16, 27),
                                   self.html_nick(nicks, 12, True, True, False, self.prefix_width * -1),
                                   (('weechat.color.chat', chat_msgs[4]),)))
        for i in range(5, len(chat_msgs)):
            chat.append(self.html_chat((9, 17, (i - 5) * 4),
                                       self.html_nick(nicks, i - 2, True, True, False, self.prefix_width * -1),
                                       (('weechat.color.chat', chat_msgs[i]),)))
        chat_empty = self.html_string(' ', self.chat_width, 'weechat.color.chat', 'weechat.color.chat_bg')

        # separator (between chat and nicklist)
        str_separator = self.html_string('&#9474;', 0, 'weechat.color.separator', 'weechat.color.chat_bg')

        # nicklist
        nicklist = []
        for index in range(0, len(nicks)):
            fg = 'weechat.bar.nicklist.color_fg'
            if nicks[index].endswith('a'):
                fg = 'weechat.color.nicklist_away'
            nicklist.append(self.html_nick(nicks, index, True, True, False, self.nicklist_width, fg, 'weechat.bar.nicklist.color_bg'))
        nicklist_empty = self.html_string('', self.nicklist_width, 'weechat.bar.nicklist.color_fg', 'weechat.bar.nicklist.color_bg')

        # print chat + nicklist
        for i in range (0, self.chat_height):
            if i < len(chat):
                str1 = chat[i]
            else:
                str1 = chat_empty
            if i < len(nicklist):
                str2 = nicklist[i]
            else:
                str2 = nicklist_empty
            html.append('%s%s%s' % (str1, str_separator, str2))

        # status
        html.append(self.html_concat((('weechat.bar.status.color_delim',      '['),
                                      ('weechat.color.status_time',           '12:34'),
                                      ('weechat.bar.status.color_delim',      '] ['),
                                      ('weechat.bar.status.color_fg',         '18'),
                                      ('weechat.bar.status.color_delim',      '] ['),
                                      ('weechat.bar.status.color_fg',         'irc'),
                                      ('weechat.bar.status.color_delim',      '/'),
                                      ('weechat.bar.status.color_fg',         'freenode'),
                                      ('weechat.bar.status.color_delim',      '] '),
                                      ('weechat.color.status_number',         '2'),
                                      ('weechat.bar.status.color_delim',      ':'),
                                      ('weechat.color.status_name',           '#weechat'),
                                      ('weechat.bar.status.color_delim',      '('),
                                      ('irc.color.item_channel_modes',        '+nt'),
                                      ('weechat.bar.status.color_delim',      '){'),
                                      ('weechat.bar.status.color_fg',         '%d' % len(nicks)),
                                      ('weechat.bar.status.color_delim',      '} ['),
                                      ('weechat.bar.status.color_fg',         'Act: '),
                                      ('weechat.color.status_data_highlight', '3'),
                                      ('weechat.bar.status.color_delim',      ':'),
                                      ('weechat.bar.status.color_fg',         '#linux'),
                                      ('weechat.bar.status.color_delim',      ','),
                                      ('weechat.color.status_data_private',   '18'),
                                      ('weechat.bar.status.color_delim',      ','),
                                      ('weechat.color.status_data_msg',       '4'),
                                      ('weechat.bar.status.color_delim',      ','),
                                      ('weechat.color.status_data_other',     '5'),
                                      ('weechat.bar.status.color_delim',      ','),
                                      ('weechat.color.status_data_other',     '6'),
                                      ('weechat.bar.status.color_delim',      ']')),
                                     width, 'weechat.bar.status.color_fg', 'weechat.bar.status.color_bg'))

        # input
        html.append(self.html_concat((('weechat.bar.input.color_delim', '['),
                                      (self.nick_prefix_color('+'),     '+'),
                                      ('irc.color.input_nick',          self.html_nick_self),
                                      ('weechat.bar.input.color_delim', '('),
                                      ('weechat.bar.input.color_fg',    'i'),
                                      ('weechat.bar.input.color_delim', ')] '),
                                      ('weechat.bar.input.color_fg',    'this is misspelled '),
                                      ('aspell.look.color',             'woord'),
                                      ('weechat.bar.input.color_fg',    ' '),
                                      ('cursor',                        ' ')),
                                     width, 'weechat.bar.input.color_fg', 'weechat.bar.input.color_bg'))

        # end
        html.append('</pre>')
        del self.html_nick_self
        return '\n'.join(html)