Re: latex error

2008-11-09 Thread Yarko T
I installed cygwin, and ran make from that.
For latex, I use MikTeX, and have good (great, broad) success using WinEdt
to control MikTex

There were some latex fixes in the trunk, so I would go to
http://www.bitbucket.org/birkenfeld/sphinx/
and download an archive of the current trunk (or if you use mercurial, just
clone the tree).

My pattern for building:

cygwin bash:

make html  # and that's all done;
make latex # no success using cygwin tex system, so stop w/ this tool here;

in explorer, go to the latex output directory (_build/latex for Sphinx) and
open the *.tex file with WinEdt

Don't try / expect to generate DVI files (I can from other sources - but not
out of Sphinx generated LaTeX) - insted let WinEdt  run LaTeXPDF.

This works so consistently and easily for me, I don't think about it
anymore...

The first few times, MikTeX would download fonts, build things under the
drive of WinEdt, and I'm sure that a couple of restarts of trying to gen
happened before my first PDF.

(Prior, I was working w/ a LeTeX setup w/ Addison Wesley style sheets - so I
had it working)

Regards,
Yarko

On Sat, Nov 8, 2008 at 11:27 PM, Roie Black (SKcon) <[EMAIL PROTECTED]>wrote:

>  I have set up a virtualenv to test Sphinx and installed everything in
> that environment with easy_install.  On my Windows box, the default Makefile
> does not work since the Windows mkdir fails. I installed mkdir.exe from
> UnxUtils and added a new MKDIR definition at the top of the Makefile
> pointing to that executable and changed all mkdir references to  $(MKDIR)
> and the make runs fine. (I suggest changing the default Makefile to make
> this easier on us Windows users.) I can build html files with no problems.
> However, running "make latex" on a new sphinx-quickstart project fails with
> an unknown node "footer" error.  I have done this same test on the latest
> development versions of both Sphinx and docutils with the same results. Am I
> doing something wrong here?
>
>
>
> Roie Black
>
> Professor, Computer Science
>
> Austin Community College
>
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Implementation of a ToDo directive

2008-11-08 Thread Yarko T
Ok - I've gotten a little further on this -  if I put a try / except in
process_todo_nodes() in the node.replace_self() call and just pass on the
exception, things seem to be ok for todo output.
Now, in htmlwriter.py, I get an "unkown_visit()"  call  for 'todolist' -
still trying to figure this out...



On Fri, Nov 7, 2008 at 6:06 PM, Yarko T <[EMAIL PROTECTED]> wrote:

> Hi Daniel,
> Thanks for posting this.   It caused me to read about extensions to
> Sphinx...
>
> I don't know if I"m missing something in config somewhere -  I put in one
> test ".. todo::"
> and the node seems to be created, but docutils/nodes.py  doesn't like that
>
> node.replace_self([])
>
> is being called on a node whose attribute is ['admonition-todo']
>
>
> I've got a todolist.rst, and a single todo test entry in the sources.   I'm
> pretty sure I've configured conf.py right (after all, the extension is
> correctly getting called - I've stepped through this to try to find what's
> going on).
>
> I've also put my new todolist in the toctree - basically just trying to
> start w/ the example usage file you'd posted.
>
> Can you help?
>
> Thanks much,
>
> Yarko
>
> On Thu, Nov 6, 2008 at 9:00 AM, <[EMAIL PROTECTED]> wrote:
>
>>
>> Thanks for your quick help. I managed to make todos show up as 'Todo:
>> content of todo'. It
>> did not work by simply putting 'Todo' in the argument list. It showed
>> up then as 'Note: Todo:'.
>> I needed to create a new node type 'todoNode' and add appropriate
>> visitors. The Sphinx documentation
>> is not up to date I think, addNode does not take any visitor arguments
>> anymore, so I helped myself
>> by using setattr on the translator object. This did the job. Maybe
>> there is a better way?
>>
>> I manged to include a target node for each todo item, but I did not
>> find how to actually insert a
>> reference to these labels in the todolist. How is this done? I cannot
>> find the code that actually
>> generates the index pages.
>>
>> I also collect all todo nodes at the environment object now.
>>
>> I have put the current version here:
>>
>> http://pastebin.com/m2b02f72b
>>
>> Regards,
>>  Daniel
>>
>> On Nov 6, 11:11 am, Georg Brandl <[EMAIL PROTECTED]> wrote:
>> > [EMAIL PROTECTED] schrieb:
>> >
>> >
>> >
>> > > Dear all,
>> >
>> > > first of all I want to thank the Sphinx developers for this great
>> > > tool. I
>> > > ported the developers manual for our openWNS (open Wireless Network
>> > > Simulator)
>> > > to Sphinx. I am still surprised how easy and intuitively the work with
>> > > Sphinx is.
>> > > So, thanks for that!
>> >
>> > > During the work on the documentation I often wanted to place ToDos
>> > > within the text to keep track of
>> > > things that still need to be documented. I think it would be
>> > > benefitial to have
>> > > a special kind of admonition (.. todo::) to place inline in the text
>> > > for this task.
>> > > Furthermore, I want these admonitions to show only if a certain flag
>> > > is set in the
>> > > configuration, such that a released version of the documentation does
>> > > not show any
>> > > todo content. In addition to that I want a separate page that collects
>> > > all todo
>> > > admonitions and provides an overview of all pending todos within the
>> > > document.
>> >
>> > That's a good idea! I'd like to include the extension when it's
>> finished.
>> >
>> >
>> >
>> > > I did not find any support for this within the current release of
>> > > Sphinx, so I started
>> > > developing a todo extension of my own. I implemented two directives:
>> > > todo & todolist
>> > > that should take care of the task. The basic functionality works now,
>> > > but I still face
>> > > some problems. You can take a look at what I have done so far here:
>> >
>> > >http://pastebin.com/f55ea9fe0
>> >
>> > > An example of how I use this example can be seen here:
>> >
>> > >http://pastebin.com/f7913c13a
>> >
>> > > The problems I have now are:
>> >
>> > > 1. I only want to include the todolist page 

Re: Latest Tip of Sphinx has a typo... startup error...

2008-11-08 Thread Yarko T
sorry - I forgot I had a branch - should have just pushed it up originally
  now I'm starting to like Bitbucket ;-)

On Sat, Nov 8, 2008 at 1:53 AM, Georg Brandl <[EMAIL PROTECTED]> wrote:

>
> yarko schrieb:
> > sphinx/application.py:  line 111:   __released__  (need two trailing
> > underscores):
> >
> >if buildername not in self.builderclasses:
> > raise SphinxError('Builder name %s not registered' %
> > buildername)
> >
> >  -  self.info(bold('Sphinx v%s, building %s' %
> > (sphinx.__released_,
> >  +  self.info(bold('Sphinx v%s, building %s' %
> > (sphinx.__released__,
> > buildername)))
> >
> > builderclass = self.builderclasses[buildername]
>
> Thanks, fixed!
>
> Georg
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Implementation of a ToDo directive

2008-11-07 Thread Yarko T
Hi Daniel,
Thanks for posting this.   It caused me to read about extensions to
Sphinx...

I don't know if I"m missing something in config somewhere -  I put in one
test ".. todo::"
and the node seems to be created, but docutils/nodes.py  doesn't like that

node.replace_self([])

is being called on a node whose attribute is ['admonition-todo']


I've got a todolist.rst, and a single todo test entry in the sources.   I'm
pretty sure I've configured conf.py right (after all, the extension is
correctly getting called - I've stepped through this to try to find what's
going on).

I've also put my new todolist in the toctree - basically just trying to
start w/ the example usage file you'd posted.

Can you help?

Thanks much,

Yarko

On Thu, Nov 6, 2008 at 9:00 AM, <[EMAIL PROTECTED]> wrote:

>
> Thanks for your quick help. I managed to make todos show up as 'Todo:
> content of todo'. It
> did not work by simply putting 'Todo' in the argument list. It showed
> up then as 'Note: Todo:'.
> I needed to create a new node type 'todoNode' and add appropriate
> visitors. The Sphinx documentation
> is not up to date I think, addNode does not take any visitor arguments
> anymore, so I helped myself
> by using setattr on the translator object. This did the job. Maybe
> there is a better way?
>
> I manged to include a target node for each todo item, but I did not
> find how to actually insert a
> reference to these labels in the todolist. How is this done? I cannot
> find the code that actually
> generates the index pages.
>
> I also collect all todo nodes at the environment object now.
>
> I have put the current version here:
>
> http://pastebin.com/m2b02f72b
>
> Regards,
>  Daniel
>
> On Nov 6, 11:11 am, Georg Brandl <[EMAIL PROTECTED]> wrote:
> > [EMAIL PROTECTED] schrieb:
> >
> >
> >
> > > Dear all,
> >
> > > first of all I want to thank the Sphinx developers for this great
> > > tool. I
> > > ported the developers manual for our openWNS (open Wireless Network
> > > Simulator)
> > > to Sphinx. I am still surprised how easy and intuitively the work with
> > > Sphinx is.
> > > So, thanks for that!
> >
> > > During the work on the documentation I often wanted to place ToDos
> > > within the text to keep track of
> > > things that still need to be documented. I think it would be
> > > benefitial to have
> > > a special kind of admonition (.. todo::) to place inline in the text
> > > for this task.
> > > Furthermore, I want these admonitions to show only if a certain flag
> > > is set in the
> > > configuration, such that a released version of the documentation does
> > > not show any
> > > todo content. In addition to that I want a separate page that collects
> > > all todo
> > > admonitions and provides an overview of all pending todos within the
> > > document.
> >
> > That's a good idea! I'd like to include the extension when it's finished.
> >
> >
> >
> > > I did not find any support for this within the current release of
> > > Sphinx, so I started
> > > developing a todo extension of my own. I implemented two directives:
> > > todo & todolist
> > > that should take care of the task. The basic functionality works now,
> > > but I still face
> > > some problems. You can take a look at what I have done so far here:
> >
> > >http://pastebin.com/f55ea9fe0
> >
> > > An example of how I use this example can be seen here:
> >
> > >http://pastebin.com/f7913c13a
> >
> > > The problems I have now are:
> >
> > > 1. I only want to include the todolist page in the TOC if the
> > > configuration flag is set.
> > >The todolist page is now always included, although it is empty if
> > > the configuration file
> > >is not set. I want it to completely vanish.
> >
> > Hmm... there's no API yet for excluding items from the TOC.
> >
> > Of course, as a hack-around, you could generate the document heading only
> > if the "todo" option is set. Then, since there is no heading in the
> document,
> > none will show up in the TOC.
> >
> > > 2. With this implementation all todo admonitions show up in the final
> > > document as
> > >'''Note: The todo description''' I want them to show up as '''Todo:
> > > The todo description'''
> >
> > If you modify your make_admonition call a bit, that should be fine. Look
> > at the seealso directive:
> >
> > seealsonode = make_admonition(
> > addnodes.seealso, name, [_('See also')], options, content,
> > lineno, content_offset, block_text, state, state_machine)
> >
> > IOW, the "arguments" arg is replaced by your wanted title.
> >
> > > 3. In the todolist I only copy the original todo. It would be nice to
> > > include additional
> > >information there, such as a link to the original todo location and
> > > the original location within the
> > >source (filename, linenumber, etc.)
> >
> > For the link to the location, you can put a "target" node at the point
> > where the todo directive occurs. Look at the index directive for an
> example.
> >
> > I see that you store a

Re: Asterisk'd image, with path

2008-11-06 Thread Yarko T
I don't know LaTeX, so I'm sure there are uses that I don't understand /
know about. If you want to follow this, it's on this thread:
http://groups.google.com/group/sphinx-dev/browse_thread/thread/c6cbe84f634a78f9/eae576fa8de1579b#eae576fa8de1579b

On Thu, Nov 6, 2008 at 4:48 AM, Yarko T <[EMAIL PROTECTED]> wrote:

>
>
> On Thu, Nov 6, 2008 at 3:57 AM, Georg Brandl <[EMAIL PROTECTED]> wrote:
>
>>
>> .
>> As for the latex title/author patch, this is actually documented :)
>> It's e.g. needed for doing author="A \\and B".
>>
>> Georg
>>
>
> This seems like there is still something not right with this
>
> If I have :
>
> Python3 Patterns \\and Idioms
>
> ===
>
>
> the LaTeX output is (which still needs hand editing --- need that to be \&
> at least)
>
> \title{Python 3 Patterns & Idioms book}
>
>
> and HTML output that is:
>
> Python 3 Patterns \and Idioms href="#python-3-patterns-and-idioms" title="Permalink to this
> headline">¶
>
>
> -
>
> A similar story follows for a source file with "... \& " or  "... \\&
> "   --- it doesn't get consistent until I did what I did...   perhaps
> there is another way, but AS IS just seems wrong
>
> There must be some way to have one RST source for the file containing the
> Title!
>
> Kind Regards,
> Yarko
>
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Asterisk'd image, with path

2008-11-06 Thread Yarko T
On Thu, Nov 6, 2008 at 3:57 AM, Georg Brandl <[EMAIL PROTECTED]> wrote:

>
> .
> As for the latex title/author patch, this is actually documented :)
> It's e.g. needed for doing author="A \\and B".
>
> Georg
>

This seems like there is still something not right with this

If I have :

Python3 Patterns \\and Idioms

===


the LaTeX output is (which still needs hand editing --- need that to be \&
at least)

\title{Python 3 Patterns & Idioms book}


and HTML output that is:

Python 3 Patterns \and Idioms¶


-

A similar story follows for a source file with "... \& " or  "... \\&
"   --- it doesn't get consistent until I did what I did...   perhaps
there is another way, but AS IS just seems wrong

There must be some way to have one RST source for the file containing the
Title!

Kind Regards,
Yarko

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Asterisk'd image, with path

2008-11-06 Thread Yarko T
saw that - thanks...

On Thu, Nov 6, 2008 at 3:57 AM, Georg Brandl <[EMAIL PROTECTED]> wrote:

>
> yarko schrieb:
> > In the current tree, this fails:
> >
> > .. image::  _images/foo.*
> >
> > The path gets lost in processing this for the builders.
> >
> > I'll have a patch for this in a moment...
>
> Thanks for the patch -- it goes in the right direction, but there
> was another glitch with it. I've fixed it in tip now.
>
> As for the latex title/author patch, this is actually documented :)
> It's e.g. needed for doing author="A \\and B".
>
> Georg
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Asterisk'd image, with path

2008-11-05 Thread Yarko T
sorry... a tab snuck in that patch set... this one is correct...

On Thu, Nov 6, 2008 at 12:50 AM, Yarko T <[EMAIL PROTECTED]> wrote:

> On Wed, Nov 5, 2008 at 10:16 PM, yarko <[EMAIL PROTECTED]> wrote:
>
>>
>> In the current tree, this fails:
>>
>> .. image::  _images/foo.*
>>
>> The path gets lost in processing this for the builders.
>>
>> I'll have a patch for this in a moment...
>>
>> Yarko
>>
>
> I also found a minor problem w/ Latex generation:  title / author was not
> being escaped for LaTeX (sections, etc. were - so this was annoying...)
>
> Here's a patch which addresses both attached.
>
> Regards,
> Yarko
>
>
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---

diff -r 4d9cc1b7c60f sphinx/environment.py
--- a/sphinx/environment.py Tue Nov 04 23:46:17 2008 +0100
+++ b/sphinx/environment.py Thu Nov 06 00:54:06 2008 -0600
@@ -621,9 +621,9 @@
 for filename in glob(path.join(self.srcdir, imgpath)):
 dir, base = path.split(filename)
 if base.lower().endswith('.pdf'):
-candidates['application/pdf'] = path.join(docdir, base)
+candidates['application/pdf'] = path.join(docdir, 
filename)
 elif base.lower().endswith('.svg'):
-candidates['image/svg+xml'] = path.join(docdir, base)
+candidates['image/svg+xml'] = path.join(docdir, 
filename)
 else:
 f = open(filename, 'rb')
 try:
@@ -631,7 +631,7 @@
 finally:
 f.close()
 if imgtype:
-candidates['image/' + imgtype] = path.join(docdir, 
base)
+candidates['image/' + imgtype] = path.join(docdir, 
filename)
 else:
 candidates['*'] = imgpath
 for imgpath in candidates.itervalues():
diff -r 4d9cc1b7c60f sphinx/latexwriter.py
--- a/sphinx/latexwriter.py Tue Nov 04 23:46:17 2008 +0100
+++ b/sphinx/latexwriter.py Thu Nov 06 00:54:06 2008 -0600
@@ -160,10 +160,10 @@
 'papersize':papersize,
 'pointsize':builder.config.latex_font_size,
 # if empty, the title is set to the first section title
-'title':document.settings.title,
+'title':document.settings.title.translate(tex_escape_map),
 'date': strftime(builder.config.today_fmt or _('%B %d, 
%Y')),
 'release':  builder.config.release,
-'author':   document.settings.author,
+'author':   document.settings.author.translate(tex_escape_map),
 'releasename':  _('Release'),
 'preamble': builder.config.latex_preamble,
 'modindexname': _('Module Index'),


Re: Asterisk'd image, with path

2008-11-05 Thread Yarko T
On Wed, Nov 5, 2008 at 10:16 PM, yarko <[EMAIL PROTECTED]> wrote:

>
> In the current tree, this fails:
>
> .. image::  _images/foo.*
>
> The path gets lost in processing this for the builders.
>
> I'll have a patch for this in a moment...
>
> Yarko
>

I also found a minor problem w/ Latex generation:  title / author was not
being escaped for LaTeX (sections, etc. were - so this was annoying...)

Here's a patch which addresses both attached.

Regards,
Yarko

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---

diff -r 4d9cc1b7c60f sphinx/environment.py
--- a/sphinx/environment.py Tue Nov 04 23:46:17 2008 +0100
+++ b/sphinx/environment.py Thu Nov 06 00:49:35 2008 -0600
@@ -621,9 +621,9 @@
 for filename in glob(path.join(self.srcdir, imgpath)):
 dir, base = path.split(filename)
 if base.lower().endswith('.pdf'):
-candidates['application/pdf'] = path.join(docdir, base)
+candidates['application/pdf'] = path.join(docdir, 
filename)
 elif base.lower().endswith('.svg'):
-candidates['image/svg+xml'] = path.join(docdir, base)
+candidates['image/svg+xml'] = path.join(docdir, 
filename)
 else:
 f = open(filename, 'rb')
 try:
@@ -631,7 +631,7 @@
 finally:
 f.close()
 if imgtype:
-candidates['image/' + imgtype] = path.join(docdir, 
base)
+candidates['image/' + imgtype] = path.join(docdir, 
filename)
 else:
 candidates['*'] = imgpath
 for imgpath in candidates.itervalues():
diff -r 4d9cc1b7c60f sphinx/latexwriter.py
--- a/sphinx/latexwriter.py Tue Nov 04 23:46:17 2008 +0100
+++ b/sphinx/latexwriter.py Thu Nov 06 00:49:35 2008 -0600
@@ -160,10 +160,10 @@
 'papersize':papersize,
 'pointsize':builder.config.latex_font_size,
 # if empty, the title is set to the first section title
-'title':document.settings.title,
+'title':document.settings.title.translate(tex_escape_map),
 'date': strftime(builder.config.today_fmt or _('%B %d, 
%Y')),
 'release':  builder.config.release,
-'author':   document.settings.author,
+'author':   document.settings.author.translate(tex_escape_map),
 'releasename':  _('Release'),
 'preamble': builder.config.latex_preamble,
 'modindexname': _('Module Index'),
@@ -339,7 +339,7 @@
 if not self.elements['title']:
 # text needs to be escaped since it is inserted into
 # the output literally
-self.elements['title'] = 
node.astext().translate(tex_escape_map)
+   self.elements['title'] = node.astext().translate(tex_escape_map)
 self.this_is_the_title = 0
 raise nodes.SkipNode
 elif isinstance(node.parent, nodes.section):


Re: ANNOUNCEMENT: New source code location

2008-11-03 Thread Yarko T
This cheat-sheet might be a useful introduction -
http://edong.net/2008v1/docs/dongwoo-Hg-120dpi.png
or http://edong.net/2008v1/docs/dongwoo-Hg-PDF.pdf


On Mon, Nov 3, 2008 at 12:51 AM, Georg Brandl <[EMAIL PROTECTED]> wrote:

>
> Gour schrieb:
> >> "Georg" == Georg Brandl <[EMAIL PROTECTED]> writes:
> >
> > Georg> Hi,
> >
> >
> > Georg> after some deliberation, I've decided to get Sphinx' source
> > Georg> control away from the Python SVN repository, and use a
> > Georg> DVCS. Since I'm already comfortable using Mercurial for other
> > Georg> projects, I've stayed with it, and decided to give the new
> > Georg> hosting site bitbucket.org a chance.
> >
> > Although I'd be more happy with bzr/LP, I congratulate you for leaving
> > SVN and moving to DVCS land!
> >
> >
> > Georg> http://www.bitbucket.org/birkenfeld/sphinx/
> >
> > I cloned the repo and here is one 2.6 warning:
> >
> > [EMAIL PROTECTED] hg] hg clone
> http://www.bitbucket.org/birkenfeld/sphinx/
> > destination directory: sphinx
> > /usr/lib/python2.6/site-packages/mercurial/demandimport.py:46:
> > DeprecationWarning: the sha module is deprecated; use the hashlib module
> >   instead mod = _origimport(head, globals, locals) Sincerely, Gour
>
> I get that too; I expect the next hg release will have fixed that.
>
> Georg
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Version control

2008-11-02 Thread Yarko T
... that should be WingIDE...

On Mon, Nov 3, 2008 at 1:50 AM, Yarko T <[EMAIL PROTECTED]> wrote:

> I use WindIDE (which I find just too useful), and I had to uninstall
> TortoiseBZR because it causes conflicts, so for both of these  I'm in
> command line mode (which, frankly, is fine).
>
>
> On Sun, Nov 2, 2008 at 9:57 AM, Hans Fangohr <[EMAIL PROTECTED]> wrote:
>
>>
>> >
>> > One nice thing about Bazaar is that they've integrated it with
>> > Tortoise on Windows, so you can do things within the GUI rather than
>> > being forced to use the command line.
>>
>> There is also TortoiseHg (http://tortoisehg.sourceforge.net/).
>>
>> Cheers,
>>
>> Hans
>>
>> >
>> >
>> > On Sat, Nov 1, 2008 at 11:25 PM, Gour <[EMAIL PROTECTED]> wrote:
>> > >>>>> "Yarko" == Yarko T <[EMAIL PROTECTED]> writes:
>> >
>> > Yarko> I used to be on the hg end also - but I was participating in
>> > Yarko> projects on Launchpad; that started to erode my
>> > preference I
>> > Yarko> think later (>1.5?)  releases of bzr are "snappier"...
>> >
>> > +1 for bzr & LP (coming from DVCS land of darcs), although not being
>> > contributor (yet), but in the process of learning Python...
>> >
>> >
>> > Sincerely,
>> > Gour
>> >
>> > --
>> >
>> > Gour  | Zagreb, Croatia  | GPG key: C6E7162D
>> > 
>> >
>> >
>> >
>> > --
>> > Bruce Eckel
>> >
>> >
>> > >
>>
>>
>> >>
>>
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Version control

2008-11-02 Thread Yarko T
I use WindIDE (which I find just too useful), and I had to uninstall
TortoiseBZR because it causes conflicts, so for both of these  I'm in
command line mode (which, frankly, is fine).

On Sun, Nov 2, 2008 at 9:57 AM, Hans Fangohr <[EMAIL PROTECTED]> wrote:

>
> >
> > One nice thing about Bazaar is that they've integrated it with
> > Tortoise on Windows, so you can do things within the GUI rather than
> > being forced to use the command line.
>
> There is also TortoiseHg (http://tortoisehg.sourceforge.net/).
>
> Cheers,
>
> Hans
>
> >
> >
> > On Sat, Nov 1, 2008 at 11:25 PM, Gour <[EMAIL PROTECTED]> wrote:
> > >>>>> "Yarko" == Yarko T <[EMAIL PROTECTED]> writes:
> >
> > Yarko> I used to be on the hg end also - but I was participating in
> > Yarko> projects on Launchpad; that started to erode my
> > preference I
> > Yarko> think later (>1.5?)  releases of bzr are "snappier"...
> >
> > +1 for bzr & LP (coming from DVCS land of darcs), although not being
> > contributor (yet), but in the process of learning Python...
> >
> >
> > Sincerely,
> > Gour
> >
> > --
> >
> > Gour  | Zagreb, Croatia  | GPG key: C6E7162D
> > 
> >
> >
> >
> > --
> > Bruce Eckel
> >
> >
> > >
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Version control (was Re: Autosummary)

2008-11-01 Thread Yarko T
I think Project Kenai bears more looking into (at least by me...)...   At
first look, it seems pretty feature reach.


On Sat, Nov 1, 2008 at 2:46 PM, Sebastien Douche <[EMAIL PROTECTED]> wrote:

>
> On Sat, Nov 1, 2008 at 19:15, Yarko T <[EMAIL PROTECTED]> wrote:
> > I'd vote for one of the later two (hg or bzr).  In fact, I've found a
> "most
> > of what I need" bazaar site (launchpad), but not found a hosting place
> > similarly configured for hg, so would be curious to hear what other
> people
> > are using for hg source hosting, that includes (at least) a wiki and
> issue
> > tracker.
>
> With Wiki / ml:
> http://sharesource.org/
> http://projectkenai.com/
> http://developer.berlios.de/
>
> w/o:
> http://www.bitbucket.org/
> http://freehg.org/
>
> You right, the all-in-place solution (Launchpad) is very comfortable.
>
> BTW, I'm using Hg for my daily job, and I'm happy. But Bzr/Git are
> very useful (Git seems to be a bit more powerful[1]), It's only a
> personal choice :).
>
>
>
> [1] In other side, Bzr/Hg use Python, developing extensions is fast.
>
>
> --
> Seb
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Version control (was Re: Autosummary)

2008-11-01 Thread Yarko T
I used to be on the hg end also - but I was participating in projects on
Launchpad; that started to erode my preference I think later (>1.5?)
releases of bzr are "snappier"...

Anyway - the supporting environment is important (look at sourceforge,
code.google, launchpad...)

Sebastian:  thanks for those links...  I'll check them out.
I've seen sharesource before, and preferred what launchpad offers for
running a project.

Regards,
Yarko



On Sat, Nov 1, 2008 at 3:00 PM, Hans Fangohr <[EMAIL PROTECTED]> wrote:

>
>
> alternate possibility to directly take the step to a DVCS.
>
> So, I'm asking all of you: what would you prefer -- SVN at Google,
> with very liberal commit policies, or Mercurial?
>
>
> While I am not contributing to sphinx, I'd like to support the vote for
> Mercurial. I have used over the years cvs and svn, then bzr and hg, and
> found hg most convincing (snappier than bzr, easy for simple things, yet
> fairly powerful if required).
>
> Cheers,
>
> Hans
>
>
>
>
> cheers,
> Georg
>
>
>
>
>
>
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Version control (was Re: Autosummary)

2008-11-01 Thread Yarko T
DVCS is nice - and lightweight on a potential contributor's local machine..

Could we keep it python-ish, so that contributing platforms don't get in the
way?
The nice thing about SVN is is seems to run everywhere

mercurial too (but you need to compile "C" code if not);
bazaar is all python;

I'd vote for one of the later two (hg or bzr).  In fact, I've found a "most
of what I need" bazaar site (launchpad), but not found a hosting place
similarly configured for hg, so would be curious to hear what other people
are using for hg source hosting, that includes (at least) a wiki and issue
tracker.

Thanks,
Yarko

On Sat, Nov 1, 2008 at 11:16 AM, Rok Garbas <[EMAIL PROTECTED]> wrote:

>
> On Sat, Nov 1, 2008 at 4:14 PM, Georg Brandl <[EMAIL PROTECTED]> wrote:
> > So, I'm asking all of you: what would you prefer -- SVN at Google,
> > with very liberal commit policies, or Mercurial?
>
> i'm not (yet) a contributor, but i'm working extensivly with sphinx
> last month and will continue in the future. it would be nice to see
> DVCS. could git be possible option?
> (http://git.or.cz/gitwiki/GitBenchmarks)
>
>
> (my intention is not to get into "best dvcs war" here, i'm just proposing
> git)
>
> --
> Rok Garbas
> http://sharbas.blogspot.com/
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Not able to generate the PDF using MikTex 2.7

2008-11-01 Thread Yarko T
I don't know all the steps (the makefile didn't cut it once the *.tex file
was generated for me), but I know that using WinEdt (which runs MixTeX)   it
all just works  you might try that.
Yarko.

On Sat, Nov 1, 2008 at 9:21 AM, Georg Brandl <[EMAIL PROTECTED]> wrote:

>
> ksachdeva schrieb:
> > Hi,
> >
> > I am able to generate HTML and tex from a very basic (actually the
> > content created by sphinx quick start) setup but when I try to
> > generate pdf using pdftex utility I get bunch of errors and nothing
> > gets generated. Again, I have not added anything to the project
> > created by sphinx quick start.
>
> Hi Kapil,
>
> You'll need to use pdflatex, not pdftex, as the executable to create
> the documents.
>
> Also note that you need to run pdflatex several times, and also makeindex
> if you want the index to be populated. The Makefile generated in the
> output directory does that for you automatically.
>
> If you have further questions, don't hesitate to ask!
>
> cheers,
> Georg
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Single-File HTML Builder, Sphinx-Build Output, rst2pdf

2008-10-28 Thread Yarko T
Just looked at that TeX Live link - will have to check that out (some
weekend, or on another PC).  Thanks for the link.

On Tue, Oct 28, 2008 at 11:28 PM, Yarko T <[EMAIL PROTECTED]> wrote:

> I had a similar experience w/ MiKTeX on my PC
> I tried getting reportlab setup (didn't try too hard) , but something was
> missing / had trouble / didn't work.
>
> I installed MiKTeX and had NO idea what packages I needed, fonts to make,
> etc. etc.
>
> So I tried LyX.  It seemed to work w/ MiKTeX, but I was helping edit a book
> written in LaTeX for AW, and LyX had trouble with that (actually, I couldn't
> send back changes easily)...
>
> Which lead me to WinEdt - It fired MiKTeX, and loaded all the missing
> pieces, builds all the needed fonts - I just watch...  It Works for me;  I
> like it.
>
> YMMV
>
> Yarko.
>
> But there's the ticket - whatever works for you.
>
>
> On Tue, Oct 28, 2008 at 10:12 PM, Doug Hellmann <[EMAIL PROTECTED]>wrote:
>
>>
>>
>> On Oct 28, 2008, at 10:36 PM, Max Battcher wrote:
>>
>> >
>> > Yarko T wrote:
>> >> As for PDF generation, just generate LaTeX and  generate PDF from
>> >> that
>> >> (I do it on a PC w/ MikTeX driven by WinEdt - I know nothing about
>> >> LaTeX, and it works great).
>> >
>> > The problem is not that the latex doesn't work, it's that rst2pdf and
>> > reportlab is a *lot* easier to setup (and make sure is correctly
>> > setup)
>> > than a latex environment and all of its dependencies.
>>
>> Once Georg pointed me to it, I found the TeX Live package to be
>> *incredibly* easy to install:
>>
>> http://www.tug.org/texlive/acquire.html
>>
>> It includes all of the pieces you need to make PDFs using the LaTeX
>> output created by sphinx.
>>
>> Doug
>>
>>
>> >>
>>
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Single-File HTML Builder, Sphinx-Build Output, rst2pdf

2008-10-28 Thread Yarko T
I had a similar experience w/ MiKTeX on my PC
I tried getting reportlab setup (didn't try too hard) , but something was
missing / had trouble / didn't work.

I installed MiKTeX and had NO idea what packages I needed, fonts to make,
etc. etc.

So I tried LyX.  It seemed to work w/ MiKTeX, but I was helping edit a book
written in LaTeX for AW, and LyX had trouble with that (actually, I couldn't
send back changes easily)...

Which lead me to WinEdt - It fired MiKTeX, and loaded all the missing
pieces, builds all the needed fonts - I just watch...  It Works for me;  I
like it.

YMMV

Yarko.

But there's the ticket - whatever works for you.


On Tue, Oct 28, 2008 at 10:12 PM, Doug Hellmann <[EMAIL PROTECTED]>wrote:

>
>
> On Oct 28, 2008, at 10:36 PM, Max Battcher wrote:
>
> >
> > Yarko T wrote:
> >> As for PDF generation, just generate LaTeX and  generate PDF from
> >> that
> >> (I do it on a PC w/ MikTeX driven by WinEdt - I know nothing about
> >> LaTeX, and it works great).
> >
> > The problem is not that the latex doesn't work, it's that rst2pdf and
> > reportlab is a *lot* easier to setup (and make sure is correctly
> > setup)
> > than a latex environment and all of its dependencies.
>
> Once Georg pointed me to it, I found the TeX Live package to be
> *incredibly* easy to install:
>
> http://www.tug.org/texlive/acquire.html
>
> It includes all of the pieces you need to make PDFs using the LaTeX
> output created by sphinx.
>
> Doug
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Single-File HTML Builder, Sphinx-Build Output, rst2pdf

2008-10-28 Thread Yarko T
As for PDF generation, just generate LaTeX and  generate PDF from that (I do
it on a PC w/ MikTeX driven by WinEdt - I know nothing about LaTeX, and it
works great).

On Tue, Oct 28, 2008 at 6:44 PM, chris <[EMAIL PROTECTED]> wrote:

>
> Try
>
> from sphinx.util.console import nocolor
> nocolor()
>
> I'm pretty sure this is how the Sphinx setuptools extension works so
> that garbage isn't printed out when running on Windows.
>
> -Chris (C)
>
> On Tue, Oct 28, 2008 at 6:25 PM, Mark Eichin <[EMAIL PROTECTED]> wrote:
> >
> > On Tue, Oct 28, 2008 at 6:50 PM, Max Battcher <[EMAIL PROTECTED]> wrote:
> >
> >> 2) The person I'm debating with has said that on dumb terminals
> >> sphinx-build outputs ANSI where it is not appropriate and thus produces
> >> unreadable output.  Should I ask him to clarify how he tested this or
> >> should I make the suggestion that sphinx-build test its environment
> >> before outputting color sequences?  (Personally, I like the colors, but
> >> this person says that dumb terminals and colorless-ttys are common in
> >> his build environment.)
> >
> > I filed that as a debian bug (#501629 but it looks like #503053 is
> > also similar) and it was marked forwarded (here?) already.  it's easy
> > enough to test - just use m-x compile in emacs to run any of the
> > sphinx commandline tools, and notice that they're full of garbage :-)
> >
> > I suggested a few possible fixes.  It's definitely a bug (fortunately
> > there's the -N workaround.)  It's not a matter of liking color or not,
> > it's a matter of what you get when you don't have it
> >
> >
> > --
> > _Mark_ <[EMAIL PROTECTED]> <[EMAIL PROTECTED]>
> >
> > >
> >
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: How do I convert a word document to reStructured text?

2008-10-28 Thread Yarko T
Bruce's approach sounds good.  There's also a python interface to Open
Office.   PyUNO (some smaple scripts there
too)
Regards,
Yarko

On Tue, Oct 28, 2008 at 1:34 PM, Bruce Eckel <[EMAIL PROTECTED]> wrote:

> Well, I've just converted my Word book to Sphinx, and "partial automation"
> is the key. Actually, you can automate a lot of it but it's a cost-benefit
> analysis each time. For example, If I had a lot more headers it would have
> made sense to write a VBA Macro to put the Rest underlines on the headers,
> but I just did it by hand.
> What I ended up doing is creating a build system that would take the word
> doc and convert it to ASCII, then do some post-processing (breaking it up
> into individual files, modifying the contents, etc.) But I kept it in Word
> and just continued to run the build until I was sure I had everything out
> that I wanted (and I jumped the gun on a few things like stripping out some
> of the indexing -- seemed like a good idea at the time but now I wish I
> hadn't). And finally I felt like I didn't need the word doc anymore and just
> started editing in Sphinx, but before that I did any edits in Word and ran
> the converter.
>
> To get you started, here's the part that automatically writes the Word doc
> into an ASCII file:
>
> if not os.path.exists("TIPython.txt") or os.path.getmtime("TIPython.doc") >
> os.path.getmtime("TIPython.txt"):
> import win32com.client
> import sys, os
> from win32com.client import constants # Run makepy (part of Pythonwin)
> if this doesn't work
> o = win32com.client.Dispatch("Word.Application")
> o.Visible = 0
> here = os.getcwd()
> o.Documents.Open(os.path.join(here, "TIPython.doc"))
> o.ActiveDocument.AcceptAllRevisions()
> o.ActiveDocument.SaveAs(FileName = os.path.join(here, "TIPython.txt"),
> FileFormat = constants.wdFormatText)
> o.ActiveDocument.Close()
> print "(TIPython.doc saved as TIPython.txt)"
>
> On Tue, Oct 28, 2008 at 10:35 AM, Martin Hans <[EMAIL PROTECTED]> wrote:
>
>>  Hi,
>> Currently our product's user manual is written in Word, but we'd like to
>> move all our documentation into Sphinx. Does anybody have an idea how I can
>> do this at least partially automatically?
>>
>> Thanks.
>>
>> Martin
>>
>>
>>
>
>
> --
> Bruce Eckel
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: LaTex / MikTeX 2.7

2008-10-16 Thread Yarko T
Yes!   Thanks much, Georg!
It didn't work at first (earlier today).  I'm not sure if:
update of sphinx code later this PM affected;
update of docutils (don't think so);
of simply  "make clean" - clear out the target area,

But now smooth as silk ;-).

doctools/trunk revision 66947;
docutils/trunk  revision  5680;

Kind regards,
Yarko


On Thu, Oct 16, 2008 at 4:06 PM, Georg Brandl <[EMAIL PROTECTED]> wrote:

>
> Yarko T schrieb:
> > I tried this patch.  Maybe I'm just doing something wrong / missing
> > something:
> >
> > I've got MikTex2.7 - ran update to make sure all packages are up to date;
> > I'm driving MikTex w/ WinEdt.
> >
> > I built (successfully) the latex this way:
> >
> > % d:sphinx\trunk\doc> sphinx-build -b latex . _build/latex
> >
> > Open sphinx.tex w/ WinEdt, and run PdfLatex chain;
> >
> > Output is still what I originally posted - identically.
>
> The patch is wrong -- it was only good for the situation where ifxetex.sty
> is available.
>
> I've now committed a fix that I think should work for all possible
> configurations to SVN.
>
> Georg
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: LaTex / MikTeX 2.7

2008-10-15 Thread Yarko T
I tried this patch.  Maybe I'm just doing something wrong / missing
something:
I've got MikTex2.7 - ran update to make sure all packages are up to date;
I'm driving MikTex w/ WinEdt.

I built (successfully) the latex this way:

% d:sphinx\trunk\doc> sphinx-build -b latex . _build/latex

Open sphinx.tex w/ WinEdt, and run PdfLatex chain;

Output is still what I originally posted - identically.



On Wed, Oct 15, 2008 at 12:58 PM, Sergey A. Lipnevich <[EMAIL PROTECTED]
> wrote:

>
> The solution is here: http://bugs.python.org/issue3909. I took it and
> created a patch against today's version of Sphinx code
> (0.5dev-20081015) so that it's easier to apply.
>
> On Oct 11, 5:36 pm, yarko <[EMAIL PROTECTED]> wrote:
> > I'm having some basic trouble w/ 0.5 trunk & MixTeX generation (I can
> > generate other books w/ this MikTeX setup, so it's not _fundamentally_
> > broken).
> >
> > Here's what comes out of pdfTeX.   The output line *hyperref using
> > default driver hpdftex*  is the only thing that potentially looks
> > suspicious to me.
> > 
> >
> ...
> > ("C:\Program Files\MiKTeX 2.7\tex\plain\misc\pdfcolor.tex")
> > ! Too many }'s.
> > l.122 }
> >
> > ?
> > --
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Followed instructions, getting errors

2008-10-14 Thread Yarko T
No Problem - as a Sphinx "newbie" I appreciate understanding it's setup.
Will be doing more with it.
Thanks for the patience (and replies) to newbie questions.

Regards,
Yarko

On Tue, Oct 14, 2008 at 1:12 PM, Pauli Virtanen <[EMAIL PROTECTED]> wrote:

>
>
> [clip: use of utf-8 and cedillas]
>
> Oops, this was already addressed; sorry for the noise.
>
> --
> Pauli Virtanen
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Followed instructions, getting errors

2008-10-14 Thread Yarko T
Thanks Peter.

On Tue, Oct 14, 2008 at 11:24 AM, Peter Hoffmann <[EMAIL PROTECTED]> wrote:

>
>
>
> On 14 Okt., 17:34, "Yarko T" <[EMAIL PROTECTED]> wrote:
>
> > Sphinx dealing w/ only one character set limits ability to typeset (Bruce
> > pointed out "facade" as an example).
>
> If the word facede is encoded im utf-8 there are no problems. Sphinx
> uses unicode internal, so there should be no character limitations.
>
> > The bigger issue is identifying & understanding where the current
> > conrtraints are in Sphinx.
>
> It is more a convention to use utf8 than a technical limitation. If
> you really want to test latin1, you can change the value
> input_enconding in sphinx/environment.py default_settings. But I think
> this is evil for production and may break other thinks.
>
> Regards Peter
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Followed instructions, getting errors

2008-10-14 Thread Yarko T
two things on this:
Bruce's filter works, is Python, is portable;

Sphinx dealing w/ only one character set limits ability to typeset (Bruce
pointed out "facade" as an example).

The bigger issue is identifying & understanding where the current
conrtraints are in Sphinx.

Regards,
Yarko

On Mon, Oct 13, 2008 at 8:59 PM, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:

>
> On linux, at least, what you're looking for is GNU "recode"...
>
> On Oct 13, 1:49 pm, "Bruce Eckel" <[EMAIL PROTECTED]> wrote:
> > For what it's worth, here's one way to change encodings. I'm just
> thrashing
> > around here so there may be a more elegant way:
> > #! /usr/bin/env python
> > import os, codecs
> >
> > for root, dirs, files in os.walk("book"):
> > for f in files:
> > if f.endswith(".txt"):
> > path = os.path.join(root, f)
> > fileObj = codecs.open(path, "r", "latin-1")
> > u = fileObj.read() # Returns a Unicode string from the
> latin-1
> > bytes in the file
> > file(path, 'w').write(u.encode("utf-8", 'replace'))
> >
> >
> >
> > On Mon, Oct 13, 2008 at 11:09 AM, Bruce Eckel <[EMAIL PROTECTED]>
> wrote:
> > > Still trying to understand the issue: Sphinx itself will not handle
> > > anything but utf-8? As you say, a bit muddy -- the above looks like a
> > > strategy pattern which suggests that Sphinx might be able to handle
> more
> > > than one kind of encoding. But perhaps other code within Sphinx
> prevents
> > > this?
> > > Sorry for the confused newbie questions, everyone. Just trying to get a
> > > handle on all this.
> >
> > > On Mon, Oct 13, 2008 at 10:26 AM, Yarko T <[EMAIL PROTECTED]> wrote:
> >
> > >> On Mon, Oct 13, 2008 at 11:17 AM, Yarko T <[EMAIL PROTECTED]> wrote:
> >
> > >>> this is a bit muddy to me:
> > >>> 
> >
> > >>> encoding = options.get('encoding', 'utf-8')
> > >>> try:
> > >>> f = codecs.open(fn, 'r', encoding)
> > >>> text = f.read()
> > >>> f.close()
> >
> > >>> So I'll guess you can use this to filter your source files (?).
> >
> > >>> Regards,
> > >>> Yarko
> >
> > >> that is to say, this strategy - create a filter based on this
> simple
> > >> I/O pattern, and run through your source tree, letting codecs do the
> > >> conversion...
> >
> > >>> On Mon, Oct 13, 2008 at 12:55 AM, Bruce Eckel <[EMAIL PROTECTED]
> >wrote:
> >
> > >>>> OK, the next question is how to make the change. The only thing I
> found
> > >>>> in the docs was a reference to the conf.py file, but changing that
> (to, for
> > >>>> example, latin-1 which should take care of it) doesn't have any
> effect.
> > >>>> Thanks for any help.
> >
> > >>>> On Sun, Oct 12, 2008 at 8:20 PM, Peter Hoffmann <[EMAIL PROTECTED]
> >wrote:
> >
> > >>>>> The problem is the word Façade. As far as I know sphinx only
> supports
> > >>>>> utf-8 file encodings, but your file changeInterface/
> > >>>>> changeInterface.txt (and some others too) use non ascii characters
> > >>>>> with 8859 file encoding.
> >
> > >>>>> If you change the file encoding to utf-8 and try again, it should
> work
> > >>>>> (beside some other errors due to wrong length of underline for
> > >>>>> headings).
> >
> > >>>>> Regards Peter
> >
> > >>>>> On 13 Okt., 03:10, "Bruce Eckel" <[EMAIL PROTECTED]> wrote:
> > >>>>> > I used sphinx-quickstart to get started, and I think I followed
> the
> > >>>>> > instructions correctly. I've attached my project, which gives me
> the
> > >>>>> > following error:
> > >>>>> > $ make html
> > >>>>> > mkdir -p _build/html _build/doctrees
> > >>>>> > sphinx-build -b html -d _build/doctrees   . _build/html
> > >>>>> > Sphinx v0.4.3, building html
> > >>>>> > trying to load pickled env... not found
> > >>>&

Re: Followed instructions, getting errors

2008-10-13 Thread Yarko T
On Mon, Oct 13, 2008 at 11:17 AM, Yarko T <[EMAIL PROTECTED]> wrote:

> this is a bit muddy to me:
> 
>
> encoding = options.get('encoding', 'utf-8')
> try:
> f = codecs.open(fn, 'r', encoding)
> text = f.read()
> f.close()
>
> So I'll guess you can use this to filter your source files (?).
>
> Regards,
> Yarko
>

that is to say, this strategy - create a filter based on this simple I/O
pattern, and run through your source tree, letting codecs do the
conversion...


>
> On Mon, Oct 13, 2008 at 12:55 AM, Bruce Eckel <[EMAIL PROTECTED]>wrote:
>
>> OK, the next question is how to make the change. The only thing I found in
>> the docs was a reference to the conf.py file, but changing that (to, for
>> example, latin-1 which should take care of it) doesn't have any effect.
>> Thanks for any help.
>>
>>
>> On Sun, Oct 12, 2008 at 8:20 PM, Peter Hoffmann <[EMAIL PROTECTED]> wrote:
>>
>>>
>>> The problem is the word Façade. As far as I know sphinx only supports
>>> utf-8 file encodings, but your file changeInterface/
>>> changeInterface.txt (and some others too) use non ascii characters
>>> with 8859 file encoding.
>>>
>>> If you change the file encoding to utf-8 and try again, it should work
>>> (beside some other errors due to wrong length of underline for
>>> headings).
>>>
>>> Regards Peter
>>>
>>>
>>> On 13 Okt., 03:10, "Bruce Eckel" <[EMAIL PROTECTED]> wrote:
>>> > I used sphinx-quickstart to get started, and I think I followed the
>>> > instructions correctly. I've attached my project, which gives me the
>>> > following error:
>>> > $ make html
>>> > mkdir -p _build/html _build/doctrees
>>> > sphinx-build -b html -d _build/doctrees   . _build/html
>>> > Sphinx v0.4.3, building html
>>> > trying to load pickled env... not found
>>> > building [html]: targets for 20 source files that are out of date
>>> > updating environment: 20 added, 0 changed, 0 removed
>>> > reading... appFrameworks/appFrameworks changeInterface/changeInterface
>>> > Exception occurred:
>>> >   File "C:\Python\Lib\site-packages\docutils\io.py", line 124, in
>>> > decode  error_details))
>>> > UnicodeError: Unable to decode input data.  Tried the following
>>> encodings:
>>> > 'utf-8'.
>>> > (UnicodeDecodeError: 'utf8' codec can't decode bytes in position
>>> 432-434:
>>> > invalid data)
>>> > The full traceback has been saved in
>>> > c:\docume~1\bruce\locals~1\temp\sphinx-err-o_ecqz.log, if you want to
>>> report
>>> > the issue to the author.
>>> > Please also report this if it was a user error, so that a better error
>>> > message c
>>> > an be provided next time.
>>> > Send reports to [EMAIL PROTECTED] Thanks!
>>> > make: *** [html] Error 1
>>> >
>>> > --
>>> > Bruce Eckel
>>> >
>>> >  book.zip
>>> > 267KAnzeigenHerunterladen
>>>
>>>
>>
>>
>> --
>> Bruce Eckel
>>
>>
>> >>
>>
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Followed instructions, getting errors

2008-10-13 Thread Yarko T
this is a bit muddy to me:
Searching the documents at http://sphinx.pocoo.org/search.html?q=latin

for latin, shows a reference about include files - indicating their encoding
(Sphinx 0.4.3 and on...)
Since a search for UTF shows a few references, including one stating "all
documentation source files must be in UTF-8", I'll assume (w/o checking the
code) that is still true.  (Strangely searching for UTF-8 returned none of
the UTF-8 references.)

Here's what the include directive does:

encoding = options.get('encoding', 'utf-8')
try:
f = codecs.open(fn, 'r', encoding)
text = f.read()
f.close()

So I'll guess you can use this to filter your source files (?).

Regards,
Yarko

On Mon, Oct 13, 2008 at 12:55 AM, Bruce Eckel <[EMAIL PROTECTED]> wrote:

> OK, the next question is how to make the change. The only thing I found in
> the docs was a reference to the conf.py file, but changing that (to, for
> example, latin-1 which should take care of it) doesn't have any effect.
> Thanks for any help.
>
>
> On Sun, Oct 12, 2008 at 8:20 PM, Peter Hoffmann <[EMAIL PROTECTED]> wrote:
>
>>
>> The problem is the word Façade. As far as I know sphinx only supports
>> utf-8 file encodings, but your file changeInterface/
>> changeInterface.txt (and some others too) use non ascii characters
>> with 8859 file encoding.
>>
>> If you change the file encoding to utf-8 and try again, it should work
>> (beside some other errors due to wrong length of underline for
>> headings).
>>
>> Regards Peter
>>
>>
>> On 13 Okt., 03:10, "Bruce Eckel" <[EMAIL PROTECTED]> wrote:
>> > I used sphinx-quickstart to get started, and I think I followed the
>> > instructions correctly. I've attached my project, which gives me the
>> > following error:
>> > $ make html
>> > mkdir -p _build/html _build/doctrees
>> > sphinx-build -b html -d _build/doctrees   . _build/html
>> > Sphinx v0.4.3, building html
>> > trying to load pickled env... not found
>> > building [html]: targets for 20 source files that are out of date
>> > updating environment: 20 added, 0 changed, 0 removed
>> > reading... appFrameworks/appFrameworks changeInterface/changeInterface
>> > Exception occurred:
>> >   File "C:\Python\Lib\site-packages\docutils\io.py", line 124, in
>> > decode  error_details))
>> > UnicodeError: Unable to decode input data.  Tried the following
>> encodings:
>> > 'utf-8'.
>> > (UnicodeDecodeError: 'utf8' codec can't decode bytes in position
>> 432-434:
>> > invalid data)
>> > The full traceback has been saved in
>> > c:\docume~1\bruce\locals~1\temp\sphinx-err-o_ecqz.log, if you want to
>> report
>> > the issue to the author.
>> > Please also report this if it was a user error, so that a better error
>> > message c
>> > an be provided next time.
>> > Send reports to [EMAIL PROTECTED] Thanks!
>> > make: *** [html] Error 1
>> >
>> > --
>> > Bruce Eckel
>> >
>> >  book.zip
>> > 267KAnzeigenHerunterladen
>>
>>
>
>
> --
> Bruce Eckel
>
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---



Re: Scale directive for images

2008-10-12 Thread Yarko T
interesting I noticed the same complaint about  rst2S5.py  yeseterday,
that rst2s5  image scaling isn't working 


On Sun, Oct 12, 2008 at 3:13 PM, Gael Varoquaux <
[EMAIL PROTECTED]> wrote:

> On Sun, Oct 12, 2008 at 09:28:32PM +0200, Gael Varoquaux wrote:
>
> > On Sun, Oct 12, 2008 at 08:41:08PM +0200, Gael Varoquaux wrote:
>
> > > Hi Sphinx!
>
> > > I have the impression that the scale directive is not honored in the
> html
> > > writer. This puzzles me a bit, as I have had a look at the source code,
> > > and the writer calls the base docutils writer to do most of the work.
> > > However I have been unable to scale my images using the scale
> directive.
>
> > I should point out that I have PIL and docutils 0.5 installed. If I run
> > rst2html on the relevant file, I get a bunch of errors due to the
> > sphinx-specific directives, but the html code I am interested in looks
> > OK:
>
> This problem is bugging me, so I am investigating it :).
> I had a look at the relevant docutils code, and I would say that the
> reason this is not working is probably because during the compilation
> docutils cannot open the image file, probably because it has not copied
> to the path where it will be found.
>
> Well, I noticed that this problem had been reported more than once
> before, and that itch must have very scratchy (or maybe I didn't want to
> work on the other things I need to work on), so I wrote a patch to
> sphinx. It is not ideal as it duplicates partly some docutils code (but
> not much). The patch is attached. It does fix the problem on my example.
>
> Gaël
>
> >
>
> Index: htmlwriter.py
> ===
> --- htmlwriter.py   (revision 66880)
> +++ htmlwriter.py   (working copy)
> @@ -11,6 +11,7 @@
>
>  import sys
>  import posixpath
> +import os
>
>  from docutils import nodes
>  from docutils.writers.html4css1 import Writer, HTMLTranslator as
> BaseTranslator
> @@ -19,6 +20,10 @@
>  from sphinx.highlighting import PygmentsBridge
>  from sphinx.util.smartypants import sphinx_smarty_pants
>
> +try:
> +import Image# check for the Python Imaging
> Library
> +except ImportError:
> +Image = None
>
>  class HTMLWriter(Writer):
> def __init__(self, builder):
> @@ -253,6 +258,23 @@
> if olduri in self.builder.images:
> node['uri'] = posixpath.join(self.builder.imgpath,
>  self.builder.images[olduri])
> +
> +if node.has_key('scale'):
> +if Image and not (node.has_key('width')
> +  and node.has_key('height')):
> +try:
> +im = Image.open(os.path.join(self.builder.srcdir,
> +olduri))
> +except (IOError, # Source image can't be found or opened
> +UnicodeError):  # PIL doesn't like Unicode paths.
> +print olduri
> +pass
> +else:
> +if not node.has_key('width'):
> +node['width'] = str(im.size[0])
> +if not node.has_key('height'):
> +node['height'] = str(im.size[1])
> +del im
> BaseTranslator.visit_image(self, node)
>
> def visit_toctree(self, node):
>
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en
-~--~~~~--~~--~--~---