Commits

Leho Kraav committed db1ada2 Merge

merge upstream 0.13-dev changes

  • Participants
  • Parent commits 49197c3, 6c8728c

Comments (0)

Files changed (293)

  * Jeroen Ruigrok van der Werven <asmodai@in-nomine.org>
  * Odd Simon Simonsen <simon-code@bvnetwork.no>
  * Remy Blank <remy.blank@pobox.com>
+ * Jun Omae <jun66j5@gmail.com>
 
 See also THANKS for people who have contributed to the project.
-Copyright (C) 2003-2009 Edgewall Software
+Copyright (C) 2003-2011 Edgewall Software
 All rights reserved.
 
 Redistribution and use in source and binary forms, with or without
-Trac 0.12.2 (? ?, 2010)
+Trac 0.12.2 (January 31, 2011)
 http://svn.edgewall.org/repos/trac/tags/trac-0.12.2
 
+This list contains only a few highlights:
+ - install: improved robustness of Trac installation if Babel is
+   installed after the fact (#9439, #9595, #9961)
+ - notifications: support for Asian character width (#4717)
+ - roadmap: fix display of progress bar in some corner cases (#9718)
+   and respect the overall_completion milestone group setting (#9721)
+ - reports: reports and queries look much better, as the columns now
+   keep the same width across groups; the absence of word wrapping in
+   reports has been fixed (#9825)
+ - web admin: improved layout (#8866, #9963)
+ - web: it's now possible to log in different Trac instances sharing
+   the same URL prefix (e.g. /project and /project-test) (#9951)
+
 Trac 0.12.1 (October 9, 2010)
 http://svn.edgewall.org/repos/trac/tags/trac-0.12.1
 
 
   [db=...]            variable for selecting database backend
   [test=...]          variable for selecting a single test file
-  [coverageopts=...]  variable containing extra optios for coverage
+  [testopts=...]      variable containing extra options for running tests
+  [coverageopts=...]  variable containing extra options for coverage
 
  ---------------- Standalone test server
 
 
 ifdef test
 all: status
-	python $(test)
+	python $(test) $(testopts)
 else
 all: help
 endif
 #
 # ----------------------------------------------------------------------------
 
+catalogs = messages messages-js tracini
+
 ifdef locale
     locales = $(locale)
 else
     locales := $(sort $(locales))
 endif
 
-messages.po = trac/locale/$(*)/LC_MESSAGES/messages.po
-messages-js.po = trac/locale/$(*)/LC_MESSAGES/messages-js.po
-messages.pot = trac/locale/messages.pot
-messages-js.pot = trac/locale/messages-js.pot
+# Note: variables only valid within a $(foreach catalog,...) evaluation
+catalog.po = trac/locale/$(*)/LC_MESSAGES/$(catalog).po
+catalog.pot = trac/locale/$(catalog).pot
+catalog_stripped = $(subst messages,,$(subst -,,$(catalog)))
+_catalog = $(if $(catalog_stripped),_)$(catalog_stripped)
 
 .PHONY: extract extraction update compile check stats summary diff
 
 init-%:
-	@[ -e $(messages.po) ] \
-	 && echo "$(messages.po) already exists" \
-	 || python setup.py init_catalog -l $(*)
-	@[ -e $(messages-js.po) ] \
-	 && echo "$(messages-js.po) already exists" \
-	 || python setup.py init_catalog_js -l $(*)
+	@$(foreach catalog,$(catalogs), \
+	    [ -e $(catalog.po) ] \
+	    && echo "$(catalog.po) already exists" \
+	    || python setup.py init_catalog$(_catalog) -l $(*);)
 
 extract extraction:
-	python setup.py extract_messages extract_messages_js
+	python setup.py $(foreach catalog,$(catalogs),\
+	    extract_messages$(_catalog))
 
 update-%:
-	python setup.py update_catalog -l $(*) update_catalog_js -l $(*)
+	python setup.py $(foreach catalog,$(catalogs), \
+	    update_catalog$(_catalog) -l $(*))
 
 ifdef locale
 update: $(addprefix update-,$(locale))
 else
 update:
-	python setup.py update_catalog update_catalog_js
+	python setup.py $(foreach catalog,$(catalogs), \
+       	    update_catalog$(_catalog))
 endif
 
 compile-%:
-	python setup.py compile_catalog -l $(*) \
-	    compile_catalog_js -l $(*) generate_messages_js -l $(*)
+	python setup.py $(foreach catalog,$(catalogs), \
+	    compile_catalog$(_catalog) -l $(*)) \
+            generate_messages_js -l $(*)
 
 ifdef locale
 compile: $(addprefix compile-,$(locale))
 else
 compile:
-	python setup.py compile_catalog compile_catalog_js
+	python setup.py $(foreach catalog,$(catalogs), \
+            compile_catalog$(_catalog))
 endif
 
 check: pre-check $(addprefix check-,$(locales))
 
 check-%:
 	@echo -n "$(@): "
-	@msgfmt --check $(messages.po) && msgfmt --check $(messages-js.po) \
-	 && echo OK
+	@$(foreach catalog,$(catalogs), \
+	    msgfmt --check $(catalog.po) &&) echo OK
 	@rm -f messages.mo
 
 stats: pre-stats $(addprefix stats-,$(locales))
 
 stats-pot:
 	@echo "translation statistics for catalog templates:"
-	@echo -n "messages.pot: "; msgfmt --statistics $(messages.pot)
-	@echo -n "messages-js.pot: "; msgfmt --statistics $(messages-js.pot) 
+	@$(foreach catalog,$(catalogs), \
+	    echo -n "$(catalog.pot): "; \
+	    msgfmt --statistics $(catalog.pot);)
+	@rm -f messages.mo
 
 stats-%:
-	@echo -n "messages.po: "; msgfmt --statistics $(messages.po)
-	@[ -e $(messages-js.po) ] \
-	 && echo -n "messages-js.po: "; msgfmt --statistics $(messages-js.po) \
-	 || echo "$(messages-js.po) doesn't exist (make init-$(*))"
+	@$(foreach catalog,$(catalogs), \
+	    [ -e $(catalog.po) ] \
+	    && echo -n "$(catalog.po): "; \
+	       msgfmt --statistics $(catalog.po) \
+	    || echo "$(catalog.po) doesn't exist (make init-$(*))";)
+	@rm -f messages.mo
 
 summary: $(addprefix summary-,$(locales))
 
 define untranslated-sh
-LC_ALL=C msgfmt --statistics $(1) 2>&1 \
+LC_ALL=C msgfmt --statistics $(catalog.pot) 2>&1 \
   | tail -1 \
   | sed -e 's/0 translated messages, \([0-9]*\) un.*/\1/'
 endef
 
 define translated-sh
-{ LC_ALL=C msgfmt --statistics $(1) 2>&1 || echo 0; } \
+{ LC_ALL=C msgfmt --statistics $(catalog.po) 2>&1 || echo 0; } \
     | tail -1 \
     | sed -e 's/[^0-9]*\([0-9]*\) translated.*/\1/'
 endef
 
 MESSAGES_TOTAL = \
-    $(eval MESSAGES_TOTAL := ( \
-        $(shell $(call untranslated-sh,$(messages.pot))) + \
-        $(shell $(call untranslated-sh,$(messages-js.pot)))))\
+    $(eval MESSAGES_TOTAL := ($(foreach catalog,$(catalogs), \
+                                  $(shell $(untranslated-sh)) + ) 0)) \
     $(MESSAGES_TOTAL)
 
 summary-%:
 	@python -c "print 'l10n/$(*): translations updated (%d%%)' \
-	    % (($(shell $(call translated-sh,$(messages.po))) + \
-	        $(shell $(call translated-sh,$(messages-js.po)))) * 100.0 \
+	    % (($(foreach catalog,$(catalogs), \
+	          $(shell $(translated-sh)) + ) 0) * 100.0 \
 	       / $(MESSAGES_TOTAL))"
+	@rm -f messages.mo
 
 diff: $(addprefix diff-,$(locales))
 
 test: unit-test functional-test
 
 unit-test: Trac.egg-info
-	python ./trac/test.py --skip-functional-tests
+	python ./trac/test.py --skip-functional-tests $(testopts)
 
 functional-test: Trac.egg-info
-	python trac/tests/functional/__init__.py -v
+	python trac/tests/functional/__init__.py -v $(testopts)
 
 test-wiki:
-	python trac/tests/allwiki.py
+	python trac/tests/allwiki.py $(testopts)
 
 # ----------------------------------------------------------------------------
 #
 
 ifdef test
 test-coverage:
-	coverage run $(test)
+	coverage run $(test) $(testopts)
 else
 test-coverage: unit-test-coverage functional-test-coverage
 endif
 
 epydoc: apiref
 apiref: doc-images
-	@python doc/runepydoc.py --config=doc/epydoc.conf \
+	@python doc/utils/runepydoc.py --config=doc/utils/epydoc.conf \
 	    $(epydocopts) $(if $(dotpath),--dotpath=$(dotpath))
 
 doc-images: $(addprefix build/,$(wildcard doc/images/*.png))
  * Erik Bray                      hyugaricdeau@gmail.com
  * Toni Brkic                     toni.brkic@switchcore.com
  * Rocky Burt                     rocky.burt@myrealbox.com
+ * Tomáš Čapek                    soulcharmer@gmail.com
  * Shane Caraveo                  shanec@activestate.com
  * Eli Carter                     eli.carter@commprove.com
  * José manuel Castroagudín Silva
  * Simon Cross                    hodgestar@gmail.com
  * Wesley Crucius                 wcrucius@sandc.com
  * Wolfram Diestel                diestel@steloj.de
- * Mujdat Dinc 
- * dju'                           
+ * Mujdat Dinc
+ * dju'
+ * Ismael de Esteban              ismael@tuenti.com
  * Juracy Filho                   juracy@gmail.com
  * Daragh Fitzpatrick             Daragh@i2i-Tech.com
  * Justin Francis
- * Markus Fuchs                   
+ * Markus Fuchs
  * Lele Gaifax
  * Raúl García
  * Axel Gembe
  * Noah Slater                    nslater@gmail.com
  * Carlos Sobrinho
  * Bill Soudan                    bill@soudan.net
- * Ludvig Strigeus                
+ * Ludvig Strigeus
  * Alexandru Szasz
  * Markus Tacker                  m@tacker.org
  * Kim Taedong                    tdkim@unimo.co.kr
 From 0.12.x to 0.13.x
 ---------------------
 
-See below.
+Note that Clearsilver based plugin are now no longer supported.
 
 From 0.11.x to 0.12.x
 ---------------------
 Also, you should be careful to check that the plugins you depend on
 have been ported to 0.11, as they most probably won't work without
 adaptation due to the numerous internal changes that occurred during
-0.11 development.  Note however that Clearsilver based plugin are
-still supported.
+0.11 development.
 
 See: http://trac.edgewall.org/wiki/TracDev/ApiChanges/0.11
 

File contrib/bugzilla2trac.py

 
 import MySQLdb
 import MySQLdb.cursors
-try:
-    from trac.env import Environment
-except:
-    from trac.Environment import Environment
 from trac.attachment import Attachment
+from trac.env import Environment
 
 if not hasattr(sys, 'setdefaultencoding'):
     reload(sys)

File contrib/checkwiki.py

         f = open(pname ,'r')
         d = f.read()
         f.close()
-    except:
+    except Exception:
         print "Missing page: %s" % pname
     return d
 

File doc/Makefile

-# Makefile for Sphinx documentation
-#
-# => deprecated, use the toplevel Makefile
-#
-# --------------------------------------------------------------------------
-
-# You can set these variables from the command line.
-SPHINXOPTS    =
-SPHINXBUILD   = env PYTHONPATH=".." sphinx-build
-PAPER         =
-
-# Internal variables.
-PAPEROPT_a4     = -D latex_paper_size=a4
-PAPEROPT_letter = -D latex_paper_size=letter
-ALLSPHINXOPTS   = -d .build/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
-
-.PHONY: help clean html web pickle htmlhelp latex changes linkcheck upload pdf
-
-help:
-	@echo "Please use \`make <target>' where <target> is one of"
-	@echo "  html      to make standalone HTML files"
-	@echo "  pickle    to make pickle files (usable by e.g. sphinx-web)"
-	@echo "  htmlhelp  to make HTML files and a HTML help project"
-	@echo "  latex     to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
-	@echo "  changes   to make an overview over all changed/added/deprecated items"
-	@echo "  linkcheck to check all external links for integrity"
-
-clean:
-	-rm -rf .build/*
-
-html:
-	mkdir -p .build/html .build/doctrees
-	$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) .build/html
-	@echo
-	@echo "Build finished. The HTML pages are in .build/html."
-
-pickle:
-	mkdir -p .build/pickle .build/doctrees
-	$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) .build/pickle
-	@echo
-	@echo "Build finished; now you can process the pickle files or run"
-	@echo "  sphinx-web .build/pickle"
-	@echo "to start the sphinx-web server."
-
-web: pickle
-
-htmlhelp:
-	mkdir -p .build/htmlhelp .build/doctrees
-	$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) .build/htmlhelp
-	@echo
-	@echo "Build finished; now you can run HTML Help Workshop with the" \
-	      ".hhp project file in .build/htmlhelp."
-
-latex:
-	mkdir -p .build/latex .build/doctrees
-	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) .build/latex
-	@echo
-	@echo "Build finished; the LaTeX files are in .build/latex."
-	@echo "Run \`make all-pdf' or \`make all-ps' in that directory to" \
-	      "run these through (pdf)latex."
-
-changes:
-	mkdir -p .build/changes .build/doctrees
-	$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) .build/changes
-	@echo
-	@echo "The overview file is in .build/changes."
-
-linkcheck:
-	mkdir -p .build/linkcheck .build/doctrees
-	$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) .build/linkcheck
-	@echo
-	@echo "Link check complete; look for any errors in the above output " \
-	      "or in .build/linkcheck/output.txt."
-
-pdf: latex
-	make -C .build/latex all-pdf
-	cp .build/latex/*.pdf .build
-New documentation coming soon.
+See the toplevel Makefile (make help).

File doc/admin/command_line.rst

-.. _admin-tracadmin:

File doc/admin/environment.rst

-.. _admin-environment:
-
-====================
-The Trac Environment
-====================
-
-.. _admin-environment-database:

File doc/admin/index.rst

Empty file removed.

File doc/admin/ini.rst

-.. _admin-ini:
-
-===========================
-The Trac Configuration File
-===========================

File doc/admin/permissions.rst

-.. _admin-permissions:

File doc/api/index.rst

    :glob:
 
    trac_*
+   tracopt_*

File doc/api/trac_attachment.rst

+:mod:`trac.attachment` -- Attachments for Trac resources
+========================================================
+
+.. module :: trac.attachment
+
+This module contains the `Attachment` model class and the
+`AttachmentModule` component which manages file attachments for any
+kind of Trac resources. Currently, the wiki pages, tickets and
+milestones all support file attachments. You can use the same utility
+methods from the `AttachmentModule` as they do for easily adding
+attachments to other kinds of resources.
+
+See also the
+:download:`attach_file_form.html <../../trac/templates/attach_file_form.html>` 
+and
+:download:`attachment.html <../../trac/templates/attachment.html>` templates
+which can be used to display the attachments.
+
+
+Interfaces
+----------
+
+.. autoclass :: IAttachmentChangeListener
+   :members:
+
+.. autoclass :: IAttachmentManipulator
+   :members:
+
+.. autoclass :: ILegacyAttachmentPolicyDelegate
+   :members:
+
+
+Classes
+-------
+
+.. autoclass :: Attachment
+   :members:
+
+Components
+----------
+
+.. autoclass :: AttachmentModule
+   :members:

File doc/api/trac_cache.rst

+:mod:`trac.cache` -- Control of cached data coherency
+=====================================================
+
+Trac is a server application which may involve multiple concurrent
+processes. The coherency of the data presented to the clients is
+ensured by the underlying database and its transaction
+handling. However, a server process will not systematically retrieve
+data from the database, as various in-memory caches are used for
+performance reasons. We could ensure the integrity of those caches in
+a single process in presence of multiple threads by the appropriate
+use of locking and by updating the caches as needed, but we also need
+a mechanism for invalidating the caches in the *other* processes.
+
+The purpose of this module is to provide a `cached` decorator_ which
+can annotate a data *retriever* method of a class for turning it into
+an attribute working like a cache. This means that an access to this
+attribute will only call the underlying retriever method once on first
+access, or only once after the cache has been invalidated, even if
+this invalidation happened in another process.
+
+.. _decorator: http://docs.python.org/glossary.html#term-decorator
+
+.. module :: trac.cache
+
+Public API
+----------
+
+.. autofunction :: cached
+
+Internal API
+------------
+
+.. autoclass :: CacheManager
+   :members:
+
+The following classes are the descriptors_ created by the `cached`
+decorator:
+
+.. _descriptors: http://docs.python.org/glossary.html#term-descriptor
+
+.. autoclass :: CachedSingletonProperty
+   :members:
+
+.. autoclass :: CachedProperty
+   :members:
+
+Both classes inherit from a common base:
+
+.. autoclass :: CachedPropertyBase
+   :members:

File doc/api/trac_core.rst

 The benefit of implementing an interface is to possibility to define
 an `ExtensionPoint` property for an `Interface`, in a `Component`
 subclass. Such a property provides a convenient way to retrieve *all*
-registered component instances for that interface.
+registered and enabled component instances for that interface.  The
+enabling of components is the responsibility of the
+`ComponentManager`, see `~ComponentManager.is_component_enabled`
+below.
 
 .. autoclass :: trac.core.ExtensionPoint
    :members:
 
 .. [*] Ok, it *might* happen that more than one component instance get
    created due to a race condition. This is usually harmless, see
-   #9418.
-
-.. todo:: would be nice to have a `:teo:` role for linking to 
-   http://trac.edgewall.org/intertrac/.
+   :teo:`#9418`.

File doc/api/trac_mimeview.rst

 Components
 ----------
 
-The :class:`Environment` is special in the sense it is not only a
-:class:`Component`, but also a :class:`ComponentManager`.
-
 .. autoclass :: trac.mimeview.api.Mimeview
    :members:
  

File doc/api/trac_util.rst

+:mod:`trac.util` -- General purpose utilities
+=============================================
+
+.. module :: trac.util
+
+The `trac.util` package is a hodgepodge of various categories of
+utilities.  If a category contains enough code in itself, it earns a
+sub-module on its own, like the following ones:
+
+.. toctree::
+   :maxdepth: 1
+   :glob:
+
+   trac_util_*
+
+
+Otherwise, the functions are direct members of the `trac.util` package
+(i.e. placed in the "__init__.py" file).
+
+Web related utilities
+---------------------
+
+.. autofunction :: trac.util.get_reporter_id
+.. autofunction :: trac.util.content_disposition
+
+OS related utilies
+------------------
+
+.. autofunction :: copytree
+.. autofunction :: create_file
+.. autofunction :: create_unique_file
+.. autofunction :: getuser
+.. autofunction :: is_path_below
+.. autofunction :: makedirs
+.. autofunction :: read_file
+.. autofunction :: rename
+
+.. autoclass :: AtomicFile
+   :members:
+.. autoclass :: NaivePopen
+   :members:
+
+Python "system" utilities
+-------------------------
+
+Complements the `inspect`, `traceback` and `sys` modules.
+
+.. autofunction :: arity
+.. autofunction :: get_last_traceback
+.. autofunction :: get_lines_from_file
+.. autofunction :: get_frame_info
+.. autofunction :: safe__import__
+.. autofunction :: get_doc
+
+Setuptools utilities
+--------------------
+
+.. autofunction :: get_module_path
+.. autofunction :: get_sources
+.. autofunction :: get_pkginfo
+
+Cryptographic related utilities
+-------------------------------
+
+.. autofunction :: hex_entropy
+.. autofunction :: md5crypt
+
+Data structures which don't fit anywhere else
+---------------------------------------------
+
+.. autoclass :: Ranges
+   :members:
+
+.. autofunction :: to_ranges
+
+Algorithmic utilities
+---------------------
+
+.. autofunction :: embedded_numbers
+.. autofunction :: pairwise
+.. autofunction :: partition
+.. autofunction :: as_int
+.. autofunction :: as_bool
+.. autofunction :: pathjoin

File doc/api/trac_util_datefmt.rst

+:mod:`trac.util.datefmt` -- Date and Time manipulation
+======================================================
+.. module :: trac.util.datefmt
+
+Since version 0.10, Trac mainly uses `datetime.datetime` objects for
+handling date and time values. This enables us to properly deal with
+timezones so that time can be shown in the user's own local time.
+
+Conversion
+----------
+
+From "anything" to a `datetime`:
+
+.. autofunction :: to_datetime
+
+A `datetime` can be converted to milliseconds and microseconds
+timestamps.  The latter is the preferred representation for dates and
+times values for storing them in the database, since Trac 0.12.
+
+.. autofunction :: to_timestamp
+
+.. autofunction :: to_utimestamp
+
+Besides `to_datetime`, there's a specialized conversion from
+microseconds timestamps to `datetime`:
+
+.. autofunction :: from_utimestamp
+
+Formatting
+----------
+
+.. autofunction :: pretty_timedelta
+
+.. autofunction :: format_datetime
+
+Derivatives:
+
+.. autofunction :: format_date
+
+.. autofunction :: format_time
+
+Propose suggestion for date/time input format:
+
+.. autofunction :: get_date_format_hint
+
+.. autofunction :: get_datetime_format_hint
+
+.. autofunction :: http_date
+
+Parsing
+-------
+
+.. autofunction :: parse_date
+
+Timezone utilities
+------------------
+
+.. autoattribute :: trac.util.datefmt.localtz
+
+.. attribute :: trac.util.datefmt.all_timezones
+
+List of all available timezones. If pytz_ is installed, this
+corresponds to a rich variety of "official" timezones, otherwise this
+corresponds to `FixedOffset` instances, ranging from GMT -12:00 to GMT
++13:00.
+
+.. autofunction :: get_timezone
+
+.. autoclass :: FixedOffset
+
+.. _pytz: http://pytz.sourceforge.net/
+

File doc/api/trac_util_html.rst

+:mod:`trac.util.html` -- HTML transformations
+=============================================
+.. module :: trac.util.html
+
+Building HTML programmatically
+------------------------------
+
+With the introduction of the Genshi_ template engine in Trac 0.11,
+most of the (X)HTML content is produced directly using Genshi
+facilities, like the builder_ or snippet templates.  The old `html`
+tag building facility is now not much more than an alias to the `tag`
+ElementFactory_, and most of the code uses directly the latter.
+
+.. autoclass :: TransposingElementFactory
+
+.. data :: html
+
+   A `TransposingElementFactory` using `str.lower` transformation.
+
+.. _Genshi: http://genshi.edgewall.org
+.. _builder: http://genshi.edgewall.org/wiki/ApiDocs/genshi.builder
+.. _ElementFactory: 
+   http://genshi.edgewall.org/wiki/ApiDocs/genshi.builder#genshi.builder:ElementFactory
+
+
+HTML clean-up and sanitization
+------------------------------
+
+.. autoclass :: TracHTMLSanitizer
+.. autoclass :: Deuglifier
+
+   See some usage examples in
+   `tracopt.mimeview.enscript.EnscriptDeuglifier` and
+   `tracopt.mimeview.php.PhpDeuglifier`.
+
+.. autofunction :: expand_markup
+.. autofunction :: plaintext
+

File doc/api/trac_util_presentation.rst

+:mod:`trac.util.presentation` -- Utilities for dynamic content generation
+=========================================================================
+
+.. module :: trac.util.presentation
+
+The following utilities are all available within Genshi templates.
+
+.. autofunction :: classes
+.. autofunction :: first_last
+.. autofunction :: group
+.. autofunction :: istext
+.. autofunction :: paginate
+.. autofunction :: separated
+.. autofunction :: to_json

File doc/api/trac_util_text.rst

+.. -*- coding: utf-8 -*-
+
+:mod:`trac.util.text` -- Text manipulation
+==========================================
+.. module :: trac.util.text
+
+The Unicode toolbox
+-------------------
+
+Trac internals are almost exclusively dealing with Unicode text,
+represented by `unicode` instances. The main advantage of using
+`unicode` over UTF-8 encoded `str` (as this used to be the case before
+version 0.10), is that text transformation functions in the present
+module will operate in a safe way on individual characters, and won't
+risk to eventually cut a multi-byte sequence in the middle. Similar
+issues with Python string handling routines are avoided as well, like
+surprising results when splitting text in lines. For example, did you
+know that "Priorità" is encoded as ``'Priorit\xc3\x0a'`` in UTF-8?
+`strip()`ping this in some locales can cut away the trailing
+``\x0a``...
+
+The drawback is that most of the outside world, while eventually
+"Unicode", is definitely not `unicode`. This is why we need to convert
+back and forth between `str` and `unicode` at the boundaries of the
+system. And more often than not we even have to guess which encoding
+is used in the incoming `str` strings.
+
+Encoding `unicode` to `str` is usually directly performed by calling
+`encode()` on the `unicode` instance, while decoding is preferably
+left to the `to_unicode` helper function, which converts `str` to
+`unicode` in a robust, guaranteed successful way.
+
+.. autofunction :: to_unicode
+
+.. autofunction :: exception_to_unicode
+
+.. autofunction :: unicode_quote
+
+.. autofunction :: unicode_quote_plus
+
+.. autofunction :: unicode_unquote
+
+.. autofunction :: unicode_urlencode
+
+.. class :: unicode_passwd
+
+.. autofunction :: console_print
+
+.. autofunction :: printout
+
+.. autofunction :: printerr
+
+.. autofunction :: raw_input
+
+.. autofunction :: to_utf8
+
+.. data :: empty
+
+   A special tag object evaluating to the empty string, used as marker
+   for missing value (as opposed to a present but empty value).
+
+Text formatting
+---------------
+
+.. autofunction :: breakable_path
+
+.. autofunction :: expandtabs
+
+.. autofunction :: normalize_whitespace
+
+.. autofunction :: obfuscate_email_address
+
+.. autofunction :: pretty_size
+
+.. autofunction :: print_table
+
+.. autofunction :: shorten_line
+
+.. autofunction :: unquote_label
+
+.. autofunction :: wrap

File doc/api/trac_versioncontrol_api.rst

+:mod:`trac.versioncontrol.api` -- Trac Version Control APIs
+===========================================================
+
+.. automodule :: trac.versioncontrol.api
+
+This module implements an abstraction layer over different kind of
+version control systems and the mechanism to access several
+heterogeneous repositories under a single "virtual" hierarchy.
+
+This abstraction was derived from the original model built around the
+Subversion system (versioned tree, changesets). It gradually became
+more general, now aiming at supporting distributed version control
+systems (DVCS).
+
+
+Interfaces
+----------
+
+.. autoclass :: IRepositoryConnector
+   :members:
+
+.. autoclass :: IRepositoryProvider
+   :members:
+
+.. autoclass :: IRepositoryChangeListener
+   :members:
+
+Components
+----------
+
+.. autoclass :: RepositoryManager
+   :members:
+ 
+Exceptions
+----------
+
+Subclasses of `ResourceNotFound`.
+
+.. autoclass :: NoSuchChangeset
+   :members:
+
+.. autoclass :: NoSuchNode
+   :members:
+
+Abstract classes
+----------------
+
+.. autoclass :: Repository
+   :members:
+
+.. autoclass :: Node
+   :members:
+
+.. autoclass :: Changeset
+   :members:

File doc/api/trac_versioncontrol_diff.rst

+:mod:`trac.versioncontrol.diff` -- Utilities for generation of diffs
+====================================================================
+
+.. automodule :: trac.versioncontrol.diff
+
+Synopsis
+--------
+
+`get_filtered_hunks`, `get_hunks` are low-level wrappers for Python's
+`difflib.SequenceMatcher`, and they generate groups of opcodes
+corresponding to diff "hunks".
+
+`get_change_extent` is a low-level utility used when marking
+intra-lines differences.
+
+`diff_blocks` is used at a higher-level to fill the template data
+needed by the "diff_div.html" template.
+
+`unified_diff` is also a higher-level function returning differences
+following the `unified diff`_ file format.
+
+Finally, `get_diff_options` is an utility for retrieving user diff 
+preferences from a `~trac.web.api.Request`.
+
+.. _unified diff: http://www.gnu.org/software/hello/manual/diff/Detailed-Unified.html
+
+Function Reference
+------------------
+
+.. autofunction :: get_change_extent
+
+.. autofunction :: get_filtered_hunks
+
+.. autofunction :: get_hunks
+
+.. autofunction :: hdf_diff
+
+.. autofunction :: diff_blocks
+
+.. autofunction :: unified_diff
+
+.. autofunction :: get_diff_options

File doc/api/trac_versioncontrol_svn_fs.rst

+:mod:`trac.versioncontrol.svn_fs` -- Subversion backend for Trac
+================================================================
+
+This module can be considered to be private. However, it can serve as
+an example implementation of a version control backend.
+
+Speaking of Subversion, we use its ``svn.fs`` layer mainly, which
+means we need direct (read) access to the repository content.
+
+Though there's no documentation for the Python API per se, the doxygen
+documentation for the `C libraries`_ are usually enough.  Another
+possible source of inspiration are the `examples`_ and the helper
+classes in the `bindings`_ themselves.
+
+.. _C libraries: http://svn.collab.net/svn-doxygen/files.html
+.. _examples: http://svn.apache.org/viewvc/subversion/trunk/tools/examples/
+.. _bindings: http://svn.apache.org/viewvc/subversion/trunk/subversion/bindings/swig/python/svn/
+
+.. automodule :: trac.versioncontrol.svn_fs
+
+
+Components
+----------
+
+.. autoclass :: SubversionConnector
+
+Concrete classes
+----------------
+
+.. autoclass :: SubversionRepository
+   :members:
+
+.. autoclass :: SubversionNode
+   :members:
+
+.. autoclass :: SubversionChangeset
+   :members:

File doc/api/trac_wiki_api.rst

+:mod:`trac.wiki.api` -- The Wiki API
+====================================
+
+.. module :: trac.wiki.api
+
+
+Interfaces
+----------
+
+The wiki module presents several possibilities of extension, for
+interacting with the Wiki application and also for extending the Wiki
+syntax.
+
+First, components can be notified of the changes happening in the
+wiki.
+
+.. autoclass :: trac.wiki.api.IWikiChangeListener
+   :members:
+
+Components can also interfere with the changes, before or after
+they're made.
+
+.. autoclass :: trac.wiki.api.IWikiPageManipulator
+   :members:
+
+Then, the Wiki syntax itself can be extended. The first and less
+intrusive way is to provide new Wiki macros or Wiki processors. Those
+are basically the same thing, as they're implemented using the
+following interface. The difference comes from the invocation
+syntax used in the Wiki markup, which manifests itself in the `args`
+parameter of :meth:`IWikiMacroProvider.expand_macro`.
+
+.. autoclass :: trac.wiki.api.IWikiMacroProvider
+   :members:
+
+The Wiki syntax can also be extended by introducing new markup.
+
+.. autoclass :: trac.wiki.api.IWikiSyntaxProvider
+   :members:
+
+The Wiki System
+---------------
+
+The wiky system provide an access to all the pages.
+
+.. autoclass :: trac.wiki.api.WikiSystem
+   :members:
+   :exclude-members: get_resource_description, resource_exists
+
+
+
+Other Functions
+---------------
+
+.. autofunction :: trac.wiki.api.parse_args
+

File doc/api/tracopt_mimeview.rst

+:mod:`tracopt.mimeview` -- Optional content generation modules
+==============================================================
+
+.. module :: tracopt.mimeview
+
+Syntax Highlighters
+-------------------
+
+.. module :: tracopt.mimeview.enscript
+
+.. autoclass :: EnscriptRenderer
+.. autoclass :: EnscriptDeuglifier
+
+   .. literalinclude:: /../tracopt/mimeview/enscript.py
+      :pyobject: EnscriptDeuglifier.rules
+
+   See also `trac.util.html.Deuglifier`.
+
+
+.. module :: tracopt.mimeview.php
+
+.. autoclass :: PHPRenderer
+.. autoclass :: PhpDeuglifier
+
+   .. literalinclude:: /../tracopt/mimeview/php.py
+      :pyobject: PhpDeuglifier.rules
+
+   See also `trac.util.html.Deuglifier`.
+
+
+.. module :: tracopt.mimeview.silvercity
+
+.. autoclass :: SilverCityRenderer
+
+
+
 # Trac documentation build configuration file, created by
 # sphinx-quickstart on Wed May 14 09:05:13 2008.
 #
-# This file is execfile()d with the current directory set to its containing dir.
+# This file is execfile()d with the current directory set to its
+# containing dir.
 #
-# The contents of this file are pickled, so don't put values in the namespace
-# that aren't pickleable (module imports are okay, they're removed automatically).
+# The contents of this file are pickled, so don't put values in the
+# namespace that aren't pickleable (module imports are okay, they're
+# removed automatically).
 #
-# All configuration values have a default value; values that are commented out
-# serve to show the default value.
+# All configuration values have a default value; values that are
+# commented out serve to show the default value.
 
 import sys, os
 
-
 # General substitutions.
 project = 'Trac'
 copyright = '2010, Edgewall Software'
+url = 'http://trac.edgewall.org'
 
 # The default replacements for |version| and |release|, also used in various
 # other places throughout the built documents.
 version = '0.13'
 # The full version, including alpha/beta/rc tags.
 release = '0.13'
+
 # Devel or Release mode for the documentation (if devel, include TODOs,
 # can also be used in conditionals: .. ifconfig :: devel)
 devel = True
 
 
 
-# If your extensions are in another directory, add it here. If the directory
-# is relative to the documentation root, use os.path.abspath to make it
-# absolute, like shown here.
+# If your extensions are in another directory, add it here. If the
+# directory is relative to the documentation root, use os.path.abspath
+# to make it absolute, like shown here.
 # sys.path.insert(0, os.path.dirname(os.path.dirname(__file__)))
 
 # General configuration
 # ---------------------
 
-# Add any Sphinx extension module names here, as strings. They can be extensions
-# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
-extensions = [
- 'sphinx.ext.autodoc',
- 'sphinx.ext.ifconfig',
- 'sphinx.ext.todo',
-]
+# Add any Sphinx extension module names here, as strings. 
+# They can be extensions coming with Sphinx (named 'sphinx.ext.*') 
+# or your custom ones.
 
-# PDF support via rst2pdf (http://code.google.com/p/rst2pdf/)
+extensions = []
+
+# -- Autodoc
+
+extensions.append('sphinx.ext.autodoc')
+
+autoclass_content = 'both'
+autodoc_member_order = 'bysource'
+
+# -- Conditional content (see setup() below)
+extensions.append('sphinx.ext.ifconfig')
+
+# -- Link to other Sphinx documentations
+extensions.append('sphinx.ext.intersphinx')
+
+intersphinx_mapping = {'python': ('http://docs.python.org/2.7', None)}
+
+# -- Keep track of :todo: items
+extensions.append('sphinx.ext.todo')
+
+todo_include_todos = devel
+
+# -- PDF support via http://code.google.com/p/rst2pdf/
 try:
     import rst2pdf
     extensions.append('rst2pdf.pdfbuilder')
 except ImportError:
     pass
 
-autoclass_content = 'both'
-autodoc_member_order = 'bysource'
-
-todo_include_todos = devel
-
 
 # Add any paths that contain templates here, relative to this directory.
-templates_path = ['.templates']
+#templates_path = ['utils/templates']
 
 # The suffix of source filenames.
 source_suffix = '.rst'
 exclude_patterns = [
     'contents.rst',
     'install',
-    'guide',
-    'admin',
 ]
 
 # If true, '()' will be appended to :func: etc. cross-reference text.
 # The style sheet to use for HTML and HTML Help pages. A file of that name
 # must exist either in Sphinx' static/ path, or in one of the custom paths
 # given in html_static_path.
-#html_style = 'default.css'
+html_style = 'tracsphinx.css'
 
 html_theme = 'sphinxdoc'
 
 
 # The name of an image file (within the static path) to place at the top of
 # the sidebar.
-#html_logo = None
+html_logo = 'images/trac_logo.png'
 
 # Add any paths that contain custom static files (such as style sheets) here,
 # relative to this directory. They are copied after the builtin static files,
 # so a file named "default.css" will overwrite the builtin "default.css".
-html_static_path = ['.static']
+html_static_path = ['utils/']
 
 # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
 # using the given strftime format.
 htmlhelp_basename = 'Tracdoc'
 
 
+modindex_common_prefix = ['trac.', 'tracopt.']
+
 
 # Options for LaTeX output
 # ------------------------
     'sphinx',
     'a4',
     'trac',
-    os.path.join(os.path.dirname(__file__), 'trac_dev_pdf.style')
+    os.path.join(os.path.dirname(__file__), 'utils', 'trac_dev_pdf.style')
 ]
 
 # Create a compressed PDF
 pdf_fit_background_mode = 'scale'
 
 def setup(app):
+    # adding role for linking to InterTrac targets on t.e.o
+    from urllib import quote
+    from docutils import nodes
+    from docutils.parsers.rst import roles
+    def teo_role(name, rawtext, text, lineno, inliner, options={}, content=[]):
+        ref = url + '/intertrac/' + quote(text)
+        roles.set_classes(options)
+        node = nodes.reference(rawtext, text, refuri=ref, **options)
+        return [node], []
+    roles.register_canonical_role('teo', teo_role)
+
+    # ifconfig variables
     app.add_config_value('devel', '', True)

File doc/contents.rst

-===========================
-Trac Documentation Contents
-===========================
-
-.. toctree::
-
-    guide/index.rst
-    install/index.rst
-    admin/index.rst

File doc/dev/testing-intro.rst

 .. index::
     pair: tests; prerequisites
 
+Running the tests
+=================
+
 Prerequisites
 -------------
 
 
 * `Pygments <http://pygments.org/>`_ (0.8+)
 * `Twill <http://twill.idyll.org/>`_ (0.9+)
-* `Figleaf <http://figleaf.idyll.org>`_ (0.6.1+, for coverage [optional])
-* `Coverage <http://nedbatchelder.com/code/coverage/>`_ (also for coverage)
+* `Coverage <http://nedbatchelder.com/code/coverage/>`_ (for coverage)
+* `Figleaf <http://darcs.idyll.org/~t/projects/figleaf/doc/>`_ (0.6.1+, alternative for coverage)
 
 Additionally, if you're on Windows, you need to get fcrypt.  See
 `Prerequisites on Windows`_ below for more information.

File doc/dev/testing.rst

    testing-database
    testing-plugins
 
-.. include :: testing-intro.rst
-
 .. todo :: write more, with testing-specific steps.

File doc/epydoc.conf

-# from http://epydoc.sourceforge.net/manual-reference.html#command-line-usage
-
-[epydoc] # Epydoc section marker (required by ConfigParser)
-
-# The list of objects to document.  Objects can be named using
-# dotted names, module filenames, or package directory names.
-# Alases for this option include "objects" and "values".
-modules: trac/, tracopt/
-
-
-# The type of output that should be generated.  Should be one
-# of: html, text, latex, dvi, ps, pdf.
-output: html
-
-# The path to the output directory.  May be relative or absolute.
-target: build/doc/epydoc
-
-# An integer indicating how verbose epydoc should be.  The default
-# value is 0; negative values will supress warnings and errors;
-# positive values will give more verbose output.
-verbosity: 1
-
-# A boolean value indicating that Epydoc should show a tracaback
-# in case of unexpected error. By default don't show tracebacks
-debug: 1
-
-# If True, don't try to use colors or cursor control when doing
-# textual output. The default False assumes a rich text prompt
-simple-term: 0
-
-
-### Generation options
-
-# The default markup language for docstrings, for modules that do
-# not define __docformat__.  Defaults to epytext.
-docformat: reStructuredText
-
-# Whether or not parsing should be used to examine objects.
-parse: yes
-
-# Whether or not introspection should be used to examine objects.
-introspect: yes
-
-# Don't examine in any way the modules whose dotted name match this
-# regular expression pattern.
-#exclude
-
-# Don't perform introspection on the modules whose dotted name match this
-# regular expression pattern.
-#exclude-introspect
-
-# Don't perform parsing on the modules whose dotted name match this
-# regular expression pattern.
-#exclude-parse
-
-# The format for showing inheritance objects.
-# It should be one of: 'grouped', 'listed', 'included'.
-inheritance: listed
-
-# Whether or not to inclue private variables.  (Even if included,
-# private variables will be hidden by default.)
-private: no
-
-# Whether or not to list each module's imports.
-imports: yes
-
-# Whether or not to include syntax highlighted source code in
-# the output (HTML only).
-sourcecode: yes
-
-# Whether or not to includea a page with Epydoc log, containing
-# effective option at the time of generation and the reported logs.
-include-log: yes
-
-
-### Output options
-
-# The documented project's name.
-name: Trac
-
-# The CSS stylesheet for HTML output.  Can be the name of a builtin
-# stylesheet, or the name of a file.
-css: doc/epydoc.css
-
-# The documented project's URL.
-url: http://trac.edgewall.org
-
-# HTML code for the project link in the navigation bar.  If left
-# unspecified, the project link will be generated based on the
-# project's name and URL.
-#link: <a href="somewhere">My Cool Project</a>
-
-# The "top" page for the documentation.  Can be a URL, the name
-# of a module or class, or one of the special names "trees.html",
-# "indices.html", or "help.html"
-top: index.html
-
-# An alternative help file.  The named file should contain the
-# body of an HTML file; navigation bars will be added to it.
-#help: my_helpfile.html
-
-# Whether or not to include a frames-based table of contents.
-frames: no
-
-# Whether each class should be listed in its own section when
-# generating LaTeX or PDF output.
-separate-classes: no
-
-
-### API linking options
-
-# Define a new API document.  A new interpreted text role
-# will be created
-#external-api: epydoc
-
-# Use the records in this file to resolve objects in the API named NAME.
-#external-api-file: epydoc:api-objects.txt
-
-# Use this URL prefix to configure the string returned for external API.
-#external-api-root: epydoc:http://epydoc.sourceforge.net/api
-
-
-### Graph options
-
-# The list of graph types that should be automatically included
-# in the output.  Graphs are generated using the Graphviz "dot"
-# executable.  Graph types include: "classtree", "callgraph",
-# "umlclass".  Use "all" to include all graph types
-#graph: umlclasstree
-## prefer the ASCII-art version for now, see comments in doc/runepydoc.py
-
-# The path to the Graphviz "dot" executable, used to generate
-# graphs.
-## dotpath: /usr/local/bin/dot
-## see Makefile
-
-# The name of one or more pstat files (generated by the profile
-# or hotshot module).  These are used to generate call graphs.
-## pstat: profile.out
-
-# Specify the font used to generate Graphviz graphs.
-# (e.g., helvetica or times).
-graph-font: Helvetica
-
-# Specify the font size used to generate Graphviz graphs.
-graph-font-size: 10
-
-
-### Return value options
-
-# The condition upon which Epydoc should exit with a non-zero
-# exit status. Possible values are error, warning, docstring_warning
-#fail-on: error

File doc/epydoc.css

-html { background: #4b4d4d url(images/bkgnd_pattern.png); margin: 0;
-  padding: 1em 1em 3em;
-}
-body { background: #fff url(images/vertbars.png) repeat-x;
-  border: 1px solid #000; color: #000; margin: 1em 0; padding: 0 1em 1em;
-}
-body, th, td {
-  font: normal small Verdana,Arial,'Bitstream Vera Sans',Helvetica,sans-serif;
-}
-h1, h2, h3, h4 {
-  font-family: Arial,Verdana,'Bitstream Vera Sans',Helvetica,sans-serif;
-  font-weight: bold; letter-spacing: -0.018em;
-}
-h1 { font-size: 19px; margin: 2em 0 .5em; }
-h2 { font-size: 16px; margin: 1.5em 0 .5em; }
-h3 { font-size: 14px; margin: 1.2em 0 .5em; }
-hr { border: none;  border-top: 1px solid #ccb; margin: 2em 0; }
-p { margin: 0 0 1em; }
-:link, :visited { text-decoration: none; border-bottom: 1px dotted #bbb;
-  color: #b00;
-}
-:link:hover, :visited:hover { background-color: #eee; color: #555; }
-
-table { border: none; border-collapse: collapse; }
-
-table.navbar { background: #000; color: #fff; margin: 2em 0 .33em; }
-table.navbar th { border: 1px solid #000; font-weight: bold; padding: 1px; }
-table.navbar :link, table.navbar :visited { border: none; color: #fff; }
-table.navbar :link:hover, table.navbar :visited:hover { background: none;
-  text-decoration: underline overline;
-}
-table.navbar th.navbar-select { background: #fff; color: #000; }
-span.breadcrumbs { color: #666; font-size: 95%; }
-h1.epydoc { border: none; color: #666;
-  font-size: x-large; margin: 1em 0 0; padding: 0;
-}
-pre.base-tree { color: #666; margin: 0; padding: 0; }
-pre.base-tree :link, pre.base-tree :visited { border: none; }
-pre.py-doctest, pre.variable, pre.rst-literal-block { background: #eee;
-  border: 1px solid #e6e6e6; color: #000; margin: 1em; padding: .25em;
-  overflow: auto;
-}
-pre.variable { margin: 0; }
-
-/* Summary tables */
-
-table.summary { margin: .5em 0; }
-table.summary tr.table-header { background: #f7f7f0; }
-table.summary td.table-header { color: #666; font-weight: bold; }
-table.summary th.group-header { background: #f7f7f0; color: #666;
-  font-size: 90%; font-weight: bold; text-align: left;
-}
-table.summary th, table.summary td { border: 1px solid #d7d7d7; }
-table.summary th th, table.summary td td { border: none; }
-table.summary td.summary table td { color: #666; font-size: 90%; }
-table.summary td.summary table br { display: none; }
-table.summary td.summary span.summary-type { font-family: monospace; 
-  font-size: 90%;
-}
-table.summary td.summary span.summary-type code { font-size: 110%; }
-p.indent-wrapped-lines { color: #999; font-size: 85%; margin: 0;
-  padding: 0 0 0 7em; text-indent: -7em;
-}
-p.indent-wrapped-lines code { color: #999; font-size: 115%; }
-p.indent-wrapped-lines :link, p.indent-wrapped-lines :visited { border: none; }
-.summary-sig { display: block; font-family: monospace; font-size: 120%;
-  margin-bottom: .5em;
-}
-.summary-sig-name { font-weight: bold; }
-.summary-sig-arg { color: #333; }
-.summary-sig :link, .summary-sig :visited { border: none; }
-.summary-name { font-family: monospace; font-weight: bold; }
-
-/* Details tables */
-
-table.details { margin: 2em 0 0; }
-div table.details { margin-top: 0; }
-table.details tr.table-header { background: transparent; }
-table.details td.table-header { border-bottom: 1px solid #ccc; padding: 2em 0 0; }
-table.details span.table-header {
-  font: bold 140% Arial,Verdana,'Bitstream Vera Sans',Helvetica,sans-serif;
-  letter-spacing: -0.018em;
-}
-table.details th, table.details td { border: none; }
-table.details th th, table.details td td { border: none; }
-table.details td { padding-left: 2em; }
-table.details td td { padding-left: 0; }
-table.details h3.epydoc { margin-left: -2em; }
-table.details h3.epydoc .sig { color: #999; font-family: monospace; }
-table.details h3.epydoc .sig-name { color: #000; }
-table.details h3.epydoc .sig-arg { color: #666; }
-table.details h3.epydoc .sig-default { font-size: 95%; font-weight: normal; }
-table.details h3.epydoc .sig-default code { font-weight: normal; }
-table.details h3.epydoc .fname { color: #999; font-size: 90%;
-  font-style: italic; font-weight: normal; line-height: 1.6em;
-}
-
-dl dt { color: #666; margin-top: 1em; }
-dl dd { margin: 0; padding-left: 2em; }
-dl.fields { margin: 1em 0; padding: 0; }
-dl.fields dt { color: #666; margin-top: 1em; }
-dl.fields dd ul { margin: 0; padding: 0; }
-div.fields { font-size: 90%; margin: 0 0 2em 2em; }
-div.fields p { margin-bottom: 0.5em; }
-
-table td.footer { color: #999; font-size: 85%; margin-top: 3em;
-  padding: 0 3em 1em; position: absolute; width: 80%; }
-table td.footer :link, table td.footer :visited { border: none; color: #999; }
-table td.footer :link:hover, table td.footer :visited:hover {
-  background: transparent; text-decoration: underline;
-}
-
-/* Syntax highlighting */
-
-.py-prompt, .py-more, .variable-ellipsis, .variable-op { color: #999; }
-.variable-group { color: #666; font-weight: bold; }
-.py-string, .variable-string, .variable-quote { color: #093; }
-.py-comment { color: #06f; font-style: italic; }
-.py-keyword { color: #00f; }
-.py-output { background: #f6f6f0; color: #666; font-weight: bold; }
-
-/* Index */
-
-table.link-index { background: #f6f6f0; border: none; margin-top: 1em; }
-table.link-index td.link-index { border: none; font-family: monospace;
-  font-weight: bold; padding: .5em 1em;
-}
-table.link-index td table, table.link-index td td { border: none; }
-table.link-index .index-where { color: #999;
-  font-family: Verdana,Arial,'Bitstream Vera Sans',Helvetica,sans-serif;
-  font-size: 90%; font-weight: normal; line-height: 1.6em;
-}
-table.link-index .index-where :link, table.link-index .index-where :visited {
-  border: none; color: #666;
-}
-h2.epydoc { color: #999; font-size: 200%; line-height: 10px; }

File doc/guide/index.rst

Empty file removed.

File doc/images/trac_logo.png

Added
New image

File doc/index.rst

-=====
-Index
-=====
-Welcome to Trac's documentation!
---------------------------------
+================================
+Trac |version| API Documentation
+================================
 
 :Release: |release|
 :Date: |today|
 
+*This is work in progress. The API is not yet fully covered, but what
+you'll find here should be accurate, otherwise it's a bug and you're
+welcome to open a ticket for reporting the problem.*
+
+Content
+=======
+
 .. toctree::
    :maxdepth: 1
 
 Indices and tables
 ==================
 
-* :ref:`genindex`
+* :ref:`General Index <genindex>`
 * :ref:`modindex`
 * :ref:`search`
 * :doc:`glossary`
 .. ifconfig:: devel
 
    * :doc:`todo`
+

File doc/runepydoc.py

-# Simple wrapper script needed to run epydoc
-
-import sys
-
-try:
-    from epydoc.cli import cli
-except ImportError:
-    print>>sys.stderr, "No epydoc installed (see http://epydoc.sourceforge.net)"
-    sys.exit(2)
-
-
-# Epydoc 3.0.1 has some trouble running with recent Docutils (>= 0.6),
-# so we work around this bug, following the lines of the fix in
-# https://bugs.gentoo.org/attachment.cgi?id=210118
-# (see http://bugs.gentoo.org/287546)
-
-try:
-    from docutils.nodes import Text
-    if not hasattr(Text, 'data'):
-        setattr(Text, 'data', property(lambda self: self.astext()))
-except ImportError:
-    print>>sys.stderr, "docutils is needed for running epydoc " \
-        "(see http://docutils.sourceforge.net)"
-    sys.exit(2)
-
-# Epydoc doesn't allow much control over the generated graphs. This is
-# bad especially for the class graph for Component which has a lot of
-# subclasses, so we need to force Left-to-Right mode.
-
-# from epydoc.docwriter.html import HTMLWriter
-# HTMLWriter_render_graph = HTMLWriter.render_graph
-# def render_graph_LR(self, graph):
-#     if graph:
-#         graph.body += 'rankdir=LR\n'
-#     return HTMLWriter_render_graph(self, graph)
-# HTMLWriter.render_graph = render_graph_LR
-
-# Well, LR mode doesn't really look better...
-# the ASCII-art version seems better in most cases.
-
-
-# Workaround "visiting unknown node type" error due to `.. note ::` 
-# This was due to the lack of Admonitions transforms. Add it.
-
-from epydoc.markup.restructuredtext import _DocumentPseudoWriter
-from docutils.transforms import writer_aux
-
-orig_get_transforms = _DocumentPseudoWriter.get_transforms
-def pseudo_get_transforms(self):
-    return orig_get_transforms(self) + [writer_aux.Admonitions]
-_DocumentPseudoWriter.get_transforms = pseudo_get_transforms
-
-# Run epydoc
-cli()
-

File doc/trac_dev_pdf.style

-# This rst2pdf stylesheet, written in RSON format (http://code.google.com/p/rson/)
-#
-# Some guidelines:
-#  - the base styles are defined in conf.py in pdf_stylesheets, the main one
-#    being the 'sphinx' stylesheet, look at it to see what can be adapted (see
-#    http://rst2pdf.googlecode.com/svn/tags/0.16/rst2pdf/styles/sphinx.style)
-#  - the numerical color specifications need to have 6 hex digits
-#    (i.e. #A00 won't work)
-
-fontsAlias:
- stdFont: Helvetica
- stdBold: Helvetica-Bold
- stdItalic: Helvetica-Oblique