source: trunk/lib/html_utility.h @ 519

Last change on this file since 519 was 519, checked in by Jari Häkkinen, 14 years ago

trac moved to new location.

  • Property svn:keywords set to Id
File size: 2.0 KB
RevLine 
[177]1#ifndef _theplu_svndigest_html_utility_
2#define _theplu_svndigest_html_utility_
3
4// $Id: html_utility.h 519 2007-12-23 20:14:50Z jari $
5
6/*
[408]7  Copyright (C) 2006 Peter Johansson
8  Copyright (C) 2007 Jari Häkkinen, Peter Johansson
[177]9
[519]10  This file is part of svndigest, http://trac.thep.lu.se/svndigest
[177]11
12  svndigest is free software; you can redistribute it and/or modify it
13  under the terms of the GNU General Public License as published by
14  the Free Software Foundation; either version 2 of the License, or
15  (at your option) any later version.
16
17  svndigest is distributed in the hope that it will be useful, but
18  WITHOUT ANY WARRANTY; without even the implied warranty of
19  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20  General Public License for more details.
21
22  You should have received a copy of the GNU General Public License
23  along with this program; if not, write to the Free Software
24  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
25  02111-1307, USA.
26*/
27
[178]28#include <fstream>
[177]29#include <iosfwd>
30#include <string>
[201]31#include <vector>
[177]32
33namespace theplu{
34namespace svndigest{
35
36  ///
[235]37  /// @brief create anchor
[177]38  ///
[376]39  /// @param url address to link to
[177]40  /// @param name text visible on page
41  /// @param level '../' is added @a level times before @a href
42  /// @param title title of anchor
43  ///
[376]44  std::string anchor(const std::string& url,
[235]45                     const std::string& name, u_int level=0, 
[498]46                     const std::string& title="",
47                     const std::string& color="");
[177]48
[178]49  ///
[376]50  /// @Brief print html footer of page
[200]51  ///
52  void print_footer(std::ostream&);
53   
54  ///
[199]55  /// @brief print html header of page
56  ///
[234]57  /// \param os stream to print to
58  /// \param name
59  /// \param level
60  /// \param
61  void print_header(std::ostream& os, std::string name, u_int level, 
62                    std::string user, std::string item, std::string path);
[199]63
64
[274]65  ///
66  /// @return if trac-revision is set in config file anchor to trac is
67  /// given otherwise just a string corresponding to passed parameter.
68  ///
[498]69  std::string trac_revision(size_t, std::string color="");
[274]70
[177]71}} // end of namespace svndigest end of namespace theplu
72
73#endif
Note: See TracBrowser for help on using the repository browser.