Merge branch 'master' of http://github.com/fnp/wolnelektury
authorLukasz <lukasz@anwajler.com>
Tue, 11 May 2010 13:38:25 +0000 (15:38 +0200)
committerLukasz <lukasz@anwajler.com>
Tue, 11 May 2010 13:38:25 +0000 (15:38 +0200)
23 files changed:
README.md
apps/catalogue/fields.py
apps/catalogue/forms.py
apps/catalogue/models.py
apps/catalogue/views.py
apps/lessons/models.py
wolnelektury/static/js/jquery.countdown-pl.js
wolnelektury/static/js/jquery.countdown.js
wolnelektury/templates/404.html
wolnelektury/templates/500.html
wolnelektury/templates/base.html
wolnelektury/templates/catalogue/book_detail.html
wolnelektury/templates/catalogue/book_list.html
wolnelektury/templates/catalogue/book_short.html
wolnelektury/templates/catalogue/book_stub_detail.html
wolnelektury/templates/catalogue/book_text.html
wolnelektury/templates/catalogue/fragment_short.html
wolnelektury/templates/catalogue/main_page.html
wolnelektury/templates/catalogue/search_no_hits.html
wolnelektury/templates/catalogue/tag_list.html
wolnelektury/templates/catalogue/tagged_object_list.html
wolnelektury/templates/catalogue/user_shelves.html
wolnelektury/templates/lessons/document_detail.html

index 3b3f033..cfc289a 100644 (file)
--- a/README.md
+++ b/README.md
@@ -40,13 +40,20 @@ How to deploy (development version)
     
     ./wolnelektury/manage.py syncdb
     ./wolnelektury/manage.py migrate
-    
-5. Import some books which are availble on http://www.wolnelektury.pl or on bitbucket mirror: http://bitbucket.org/lqc/wlbooks/
 
-6. Run the server
+5. Run the server
 
    ./wolnelektury/manage.py runserver
 
+    
+6. Import some books which are available on http://www.wolnelektury.pl or on bitbucket mirror: http://bitbucket.org/lqc/wlbooks/
+   If you use Bitbucket, you also need Mercurial to fetch books (you can install it using: pip install mercurial).
+   After downloading books, log into administration, go to Books and choose 'Browse' to select book file,
+   then fire 'Import book' to upload it. Some books have invalid XML, so you can get an error
+   (just ignore it and look for other books).
+   
+
+
 Full list of used open-source software
 ======================================
 
@@ -131,4 +138,4 @@ Authors
 =======
  
  * Marek Stępniowski  <marek@stepniowski.com>
- * Łukasz Rekucki <lrekucki@gmail.com>
\ No newline at end of file
+ * Łukasz Rekucki <lrekucki@gmail.com>
index 160167e..654dbfb 100644 (file)
@@ -42,7 +42,7 @@ class JSONFormField(forms.CharField):
             loads(value)
             return value
         except ValueError, e:
-            raise forms.ValidationError('Enter a valid JSON value. Error: %s' % e)
+            raise forms.ValidationError(_('Enter a valid JSON value. Error: %s') % e)
 
 
 class JSONField(models.TextField):
index b040ef9..076282b 100644 (file)
@@ -3,6 +3,7 @@
 # Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
 #
 from django import forms
+from django.utils.translation import ugettext_lazy as _
 from slughifi import slughifi
 
 from catalogue.models import Tag, Book
@@ -24,7 +25,7 @@ class SearchForm(forms.Form):
     def __init__(self, *args, **kwargs):
         tags = kwargs.pop('tags', [])
         super(SearchForm, self).__init__(*args, **kwargs)
-        self.fields['q'].widget.attrs['title'] = u'tytuł, autor, motyw/temat, epoka, rodzaj, gatunek'
+        self.fields['q'].widget.attrs['title'] = _('title, author, theme/topic, epoch, kind, genre')
         self.fields['tags'].initial = '/'.join(tag.slug for tag in Tag.get_tag_list(tags))
 
 
@@ -40,7 +41,7 @@ class ObjectSetsForm(forms.Form):
     def __init__(self, obj, user, *args, **kwargs):        
         super(ObjectSetsForm, self).__init__(*args, **kwargs)
         self.fields['set_ids'] = forms.MultipleChoiceField(
-            label=u'Półki',
+            label=_('Shelves'),
             required=False,
             choices=[(tag.id, "%s (%s)" % (tag.name, tag.book_count)) for tag in Tag.objects.filter(category='set', user=user)],
             initial=[tag.id for tag in obj.tags.filter(category='set', user=user)],
@@ -53,7 +54,7 @@ class NewSetForm(forms.Form):
     
     def __init__(self, *args, **kwargs):
         super(NewSetForm, self).__init__(*args, **kwargs)
-        self.fields['name'].widget.attrs['title'] = u'nazwa nowej półki'
+        self.fields['name'].widget.attrs['title'] = _('Name of the new shelf')
         
     def save(self, user, commit=True):
         name = self.cleaned_data['name']
index b760ecc..59011fd 100644 (file)
@@ -138,7 +138,7 @@ class Book(models.Model):
 
             formats = []
             if self.html_file:
-                formats.append(u'<a href="%s">Czytaj online</a>' % reverse('book_text', kwargs={'slug': self.slug}))
+                formats.append(u'<a href="%s">%s</a>' % (reverse('book_text', kwargs={'slug': self.slug}), _('Read online')))
             if self.pdf_file:
                 formats.append(u'<a href="%s">PDF</a>' % self.pdf_file.url)
             if self.odt_file:
@@ -218,7 +218,7 @@ class Book(models.Model):
             book_shelves = []
         else:
             if not overwrite:
-                raise Book.AlreadyExists('Book %s already exists' % book_slug)
+                raise Book.AlreadyExists(_('Book %s already exists') % book_slug)
             # Save shelves for this book
             book_shelves = list(book.tags.filter(category='set'))
         
@@ -261,7 +261,7 @@ class Book(models.Model):
                     child_book.parent_number = n
                     child_book.save()
                 except Book.DoesNotExist, e:
-                    raise Book.DoesNotExist(u'Book with slug = "%s" does not exist.' % slug)
+                    raise Book.DoesNotExist(_('Book with slug = "%s" does not exist.') % slug)
         
         book_descendants = list(book.children.all())
         while len(book_descendants) > 0:
@@ -383,5 +383,4 @@ class BookStub(models.Model):
     class Meta:
         ordering = ('title',)
         verbose_name = _('book stub')
-        verbose_name_plural = _('book stubs')
-
+        verbose_name_plural = _('book stubs')
\ No newline at end of file
index b4fb092..7cbba27 100644 (file)
@@ -260,7 +260,7 @@ def book_sets(request, slug):
     book_sets = book.tags.filter(category='set', user=request.user)
     
     if not request.user.is_authenticated():
-        return HttpResponse('<p>Aby zarządzać swoimi półkami, musisz się zalogować.</p>')
+        return HttpResponse(_('<p>To maintain your shelves you need to be logged in.</p>'))
     
     if request.method == 'POST':
         form = forms.ObjectSetsForm(book, request.user, request.POST)
@@ -278,7 +278,7 @@ def book_sets(request, slug):
             
             book.tags = new_shelves + list(book.tags.filter(~Q(category='set') | ~Q(user=request.user)))
             if request.is_ajax():
-                return HttpResponse('<p>Półki zostały zapisane.</p>')
+                return HttpResponse(_('<p>Shelves were sucessfully saved.</p>'))
             else:
                 return HttpResponseRedirect('/')
     else:
@@ -302,9 +302,9 @@ def remove_from_shelf(request, shelf, book):
         shelf.book_count -= 1
         shelf.save()
 
-        return HttpResponse('Usunięto')
+        return HttpResponse(_('Book was successfully removed from the shelf'))
     else:
-        return HttpResponse('Książki nie ma na półce')
+        return HttpResponse(_('This book is not on the shelf'))
 
 
 def collect_books(books):
@@ -337,7 +337,7 @@ def download_shelf(request, slug):
         formats = ['pdf', 'odt', 'txt', 'mp3', 'ogg']
     
     # Create a ZIP archive
-    temp = temp = tempfile.TemporaryFile()
+    temp = tempfile.TemporaryFile()
     archive = zipfile.ZipFile(temp, 'w')
     
     for book in collect_books(models.Book.tagged.with_all(shelf)):
@@ -400,7 +400,7 @@ def new_set(request):
         new_set = new_set_form.save(request.user)
 
         if request.is_ajax():
-            return HttpResponse(u'<p>Półka <strong>%s</strong> została utworzona</p>' % new_set)
+            return HttpResponse(_('<p>Shelf <strong>%s</strong> was successfully created</p>') % new_set)
         else:
             return HttpResponseRedirect('/')
 
@@ -415,7 +415,7 @@ def delete_shelf(request, slug):
     user_set.delete()
 
     if request.is_ajax():
-        return HttpResponse(u'<p>Półka <strong>%s</strong> została usunięta</p>' % user_set.name)
+        return HttpResponse(_('<p>Shelf <strong>%s</strong> was successfully removed</p>') % user_set.name)
     else:
         return HttpResponseRedirect('/')
 
@@ -474,10 +474,10 @@ def import_book(request):
             info = sys.exc_info()
             exception = pprint.pformat(info[1])
             tb = '\n'.join(traceback.format_tb(info[2]))
-            return HttpResponse("An error occurred: %s\n\n%s" % (exception, tb), mimetype='text/plain')
-        return HttpResponse("Book imported successfully")
+            return HttpResponse(_("An error occurred: %s\n\n%s") % (exception, tb), mimetype='text/plain')
+        return HttpResponse(_("Book imported successfully"))
     else:
-        return HttpResponse("Error importing file: %r" % book_import_form.errors)
+        return HttpResponse(_("Error importing file: %r") % book_import_form.errors)
 
 
 
@@ -486,4 +486,4 @@ def clock(request):
     in a format suitable for Date.parse()
     """
     from datetime import datetime
-    return HttpResponse(datetime.now().strftime('%Y/%m/%d %H:%M:%S'))
+    return HttpResponse(datetime.now().strftime('%Y/%m/%d %H:%M:%S'))
\ No newline at end of file
index b3c79d7..dc113ed 100644 (file)
@@ -8,7 +8,7 @@ from django.utils.translation import ugettext_lazy as _
 from os import path
 
 class Document(models.Model):
-    """Dokument - materiał pomocniczy dla nauczycieli."""
+    """Document - hand-out for teachers"""
     title = models.CharField(_('title'), max_length=120)
     slug = models.SlugField(_('slug'))
     file = models.FileField(_('file'), upload_to='lessons/document')
index 4d6d1d4..10f84d4 100644 (file)
@@ -19,4 +19,4 @@
                }\r
        };\r
        $.countdown.setDefaults($.countdown.regional['pl']);\r
-})(jQuery);\r
+})(jQuery);
\ No newline at end of file
index 11d5506..06f6125 100644 (file)
@@ -6,7 +6,7 @@
    Please attribute the author if you use it. */
 
 /* Modified by Radek Czajka, Fundacja Nowoczesna Polska (radoslaw.czajka(at)nowoczesnapolska.org.pl) */
-w
+
 /* Display a countdown timer.
    Attach it with options like:
    $('div selector').countdown(
index b4968a2..288e050 100644 (file)
@@ -14,7 +14,7 @@
 <a href="/"><img src="/static/img/logo.png" /></a>
 <p class="haj" style="font-weight: bold">{% trans "Site does not exist" %}</p>
 <p>
-{% trans "We are sorry, but this site does not exist. Please check if you entered correct address or go to "%} <a href="/">{% trans "homepage" %}</a>.
+{% trans "We are sorry, but this site does not exist. Please check if you entered correct address or go to "%} <a href="/">{% trans "main page" %}</a>.
 </p>
 
 <script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
index e778d4f..412ea10 100644 (file)
@@ -14,7 +14,7 @@
 <a href="/"><img src="/static/img/logo.png" /></a>
 <p class="haj" style="font-weight: bold">{% trans "Server error" %}</p>
 <p>
-{% trans "We are sorry for your inconvenience, but server error occured. We are working on fixing it as soon as possible. Meanwhile, please go to " %}<a href="/">{% trans "homepage" %}</a>.
+{% trans "We are sorry for your inconvenience, but server error occured. We are working on fixing it as soon as possible. Meanwhile, please go to " %}<a href="/">{% trans "main page" %}</a>.
 </p>
 
 <script src="http://www.google-analytics.com/urchin.js" type="text/javascript">
index 7538206..c69da07 100644 (file)
@@ -33,7 +33,7 @@
             <div id="user-info" style="display:none">
                 {% if user.is_authenticated %}
                     <p>
-                        {% trans "Welcome" %},<strong>{{ user.username }}</strong>
+                        {% trans "Welcome" %}, <strong>{{ user.username }}</strong>
                         | <a href="{% url user_shelves %}" id="user-shelves-link">{% trans "Your shelves" %}</a>
                         {% if user.is_staff %}
                         | <a href="/admin/">{% trans "Administration" %}</a>
         <div class="clearboth"></div>
         <div id="footer">
             <p>
-                Wolne Lektury to projekt prowadzony przez <a href="http://nowoczesnapolska.org.pl/">Fundację Nowoczesna
-                Polska</a>. Reprodukcje cyfrowe wykonane przez <a href="http://www.bn.org.pl/">Bibliotekę Narodową</a>
-                z egzemplarzy pochodzących ze zbiorów BN. Hosting <a href="http://eo.pl/">EO Networks</a>.
+               {% blocktrans %}
+                               Wolne Lektury is a project lead by <a href="http://nowoczesnapolska.org.pl/">Modern Poland Foundation</a>.
+                               Digital reproductions are made by <a href="http://www.bn.org.pl/">The National Library</a>, based on TNL resources. 
+                               Hosting <a href="http://eo.pl/">EO Networks</a>.
+                               {% endblocktrans %}
             </p>
             <p>
-                Fundacja Nowoczesna Polska, 00-514 Warszawa, ul. Marszałkowska 84/92 lok. 125, tel/fax: (22) 621-30-17,
+               {% blocktrans %}
+                               Modern Poland Foundation, 00-514 Warsaw, ul. Marszałkowska 84/92 lok. 125, tel/fax: (22) 621-30-17
                 e-mail: <a href="mailto:fundacja@nowoczesnapolska.org.pl">fundacja@nowoczesnapolska.org.pl</a>
+                               {% endblocktrans %}
             </p>
 
                        {% sponsor_page "footer" %}
         pageTracker._trackPageview();
         </script>
     </body>
-</html>
+</html>
\ No newline at end of file
index f436353..c249fa5 100644 (file)
@@ -2,14 +2,14 @@
 {% load i18n %}
 {% load catalogue_tags pagination_tags %}
 
-{% block title %}{{ book.title }} w WolneLektury.pl{% endblock %}
+{% block title %}{{ book.title }} {% trans "on WolneLektury.pl" %}{% endblock %}
 
 {% block bodyid %}book-detail{% endblock %}
 
 {% block body %}
     <h1>{{ book.title }}, {{ categories.author|join:", " }}</h1>
     <form action="{% url search %}" method="get" accept-charset="utf-8" id="search-form">
-        <p>{{ form.q }} <input type="submit" value="{% trans "Search" %}" /> <strong>{% trans "or" %}</strong> <a href="{% url main_page %}">{% trans "return to homepage" %}</a></p>
+        <p>{{ form.q }} <input type="submit" value="{% trans "Search" %}" /> <strong>{% trans "or" %}</strong> <a href="{% url main_page %}">{% trans "return to main page" %}</a></p>
     </form>
     
     <div id="books-list">
index 281e5e7..3e6a9c5 100644 (file)
@@ -4,10 +4,10 @@
 
 {% block bodyid %}book-a-list{% endblock %}
 
-{% block title %}{% trans "Alphabetical listing of works on" %}Alfabetyczny spis utworów w WolneLektury.pl{% endblock %}
+{% block title %}{% trans "Alphabetical listing of works on WolneLektury.pl" %}{% endblock %}
 
 {% block body %}
-    <h1>Alfabetyczny spis utworów</h1>
+    <h1>{% trans "Alphabetical listing of works" %}</h1>
     <form action="{% url search %}" method="GET" accept-charset="utf-8" id="search-form">
         <p>{{ form.q }} <input type="submit" value="{% trans "Search" %}" /> <strong>{% trans "or" %}</strong> <a href="{% url main_page %}">{% trans "return to main page" %}</a></p>
     </form>
index 2cc8328..8b36718 100644 (file)
@@ -15,4 +15,4 @@
         {% endif %}
         <p style="margin: 0">{% trans "Categories" %}: {{ tags|join:", " }}</p>
     </div>
-</div>
+</div>
\ No newline at end of file
index 5037ecb..9ed3a8b 100644 (file)
@@ -1,37 +1,35 @@
 {% extends "base.html" %}
+{% load i18n %}
 {% load catalogue_tags pagination_tags %}
 
-{% block title %}Lektura {{ book.title }} w WolneLektury.pl{% endblock %}
+{% block title %}{{ book.title }} w WolneLektury.pl{% endblock %}
 
 {% block bodyid %}book-stub-detail{% endblock %}
 
 {% block body %}
     <h1>{{ book.title }}, {{ book.author }}</h1>
     <form action="{% url search %}" method="get" accept-charset="utf-8" id="search-form">
-        <p>{{ form.q }} <input type="submit" value="Szukaj" /> <strong>lub</strong> <a href="{% url main_page %}">wróć do strony głównej</a></p>
+        <p>{{ form.q }} <input type="submit" value="{% trans "Search" %}" /> <strong>{% trans "or" %}</strong> <a href="{% url main_page %}">{% trans "return to main page" %}</a></p>
     </form>
     
     <div id="books-list">
     {% if book.in_pd %}
-       To dzieło znajduje się w domenie publicznej i niedługo zostanie
-       opublikowane w szkolnej bibliotece internetowej Wolne Lektury. 
+               {% trans "This author's works are in public domain and will be published on Internet school library of Wolne Lektury soon." %} 
        {% else %}
            {% if book.pd %}
-                   To dzieło przejdzie
-                       do zasobów domeny publicznej i będzie mogło być publikowane bez
-                       żadnych ograniczeń za: 
+                       {% trans "This author's works will become part of public domain and will be allowed to be published without restrictions in:" %}
                    {% include "catalogue/pd_counter.html" %}
                {% else %}
-                   To dzieło objęte jest prawem autorskim. 
+                   {% trans "This author's works are copyrighted." %}
                {% endif %}
        {% endif %}
     {% include "info/join_us.html" %}
     </div>
 
     <div id="set-window">
-        <div class="header"><a href="#" class="jqmClose">Zamknij</a></div>
+        <div class="header"><a href="#" class="jqmClose">{% trans "Close" %}</a></div>
         <div class="target">
-            <p><img src="/static/img/indicator.gif" alt="*"/> Ładowanie</p>
+            <p><img src="/static/img/indicator.gif" alt="*"/> {% trans "Loading" %}</p>
         </div>
     </div>
 {% endblock %}
\ No newline at end of file
index 55eef8e..39934f8 100644 (file)
@@ -14,7 +14,7 @@
     <body>
         <div id="menu">
             <ul>
-                <li><a href="#toc">{% trans "Table of content" %}</a></li>
+                <li><a href="#toc">{% trans "Table of contents" %}</a></li>
                 <li><a href="#themes">{% trans "Themes" %}</a></li>
             </ul>
         </div>
index 24eeef3..ccca721 100644 (file)
@@ -1,8 +1,5 @@
 {% load i18n %}
 <div class="fragment">
-    {# <div class="change-sets"> #}
-    {#     <a href="{% url catalogue.views.fragment_sets fragment.id %}" class="jqm-trigger">Półki</a> #}
-    {# </div> #}
     {% if fragment.short_text %}
     <div class='fragment-short-text'>
         {{ fragment.short_text|safe }}
index be6d900..1566750 100644 (file)
         </div>
         <div id="you-can-help">
             <h2>{% trans "You can help us!" %}</h2>
-            <p>{% trans "Works appended constantly to " %}Utwory włączane sukcesywnie do naszej biblioteki staramy się opracowywać jak najdokładniej. Jest to możliwe tylko dzięki współpracującym z nami wolontariuszom.</p>
-            <p>Zapraszamy wszystkie osoby, które chcą współtworzyć szkolną bibliotekę internetową Wolne Lektury.</p>
-            <p class="see-more"><a href="{% url help_us %}">Zobacz więcej ⇒</a></p>
+            <p>{% trans "We try our best to elaborate works appended to our library. It is possible only due to support of our volunteers." %}</p>
+            <p>{% trans "We invite people who want to take part in developing Internet school library Wolne Lektury." %}</p>
+            <p class="see-more"><a href="{% url help_us %}">{% trans "See more" %} ⇒</a></p>
         </div>
         <div id="about-us">
-            <h2>O projekcie</h2>
-            <p>Biblioteka internetowa z lekturami szkolnymi „Wolne Lektury” (<a href="http://wolnelektury.pl">www.wolnelektury.pl</a>) to projekt realizowany przez Fundację Nowoczesna Polska. Działa od 2007 roku i udostępnia w swoich zbiorach lektury szkolne, które są zalecane do użytku przez Ministerstwo Edukacji Narodowej i które trafiły już do domeny publicznej.
+            <h2>{% trans "About us" %}</h2>
+            <p>
+               {% blocktrans %}
+                       Internet library with school readings „Wolne Lektury” (<a href="http://wolnelektury.pl">www.wolnelektury.pl</a>) is a project made by Modern Poland Foundation. It started in 2007 and shares school readings, which are recommended by Ministry of National Education and are in public domain.
+                       {% endblocktrans %}
             </p>
-            <p class="see-more"><a href="{% url about_us %}">Zobacz więcej ⇒</a></p>
+            <p class="see-more"><a href="{% url about_us %}">{% trans "See more" %} ⇒</a></p>
         </div>
     </div>
-{% endblock %}
+{% endblock %}
\ No newline at end of file
index 8e4e788..b2a71c8 100644 (file)
@@ -1,7 +1,8 @@
 {% extends "base.html" %}
+{% load i18n %}
 {% load catalogue_tags pagination_tags %}
 
-{% block title %}Wyszukiwanie w WolneLektury.pl{% endblock %}
+{% block title %}{% trans "Search in WolneLektury.pl" %}{% endblock %}
 
 {% block bodyid %}tagged-object-list{% endblock %}
 
     {% breadcrumbs tags %}
     
     <div id="books-list">
-        <p>Wyszukiwanie <i>{{ query }}</i> nie dało rezultatu.</p>
+        <p>{% trans "Search of " %}<i>{{ query }}</i> {% trans "did not match any resources." %}</p>
         {% include "info/join_us.html" %}
     </div>
 
     <div id="set-window">
-        <div class="header"><a href="#" class="jqmClose">Zamknij</a></div>
+        <div class="header"><a href="#" class="jqmClose">{% trans "Close" %}</a></div>
         <div class="target">
-            <p><img src="/static/img/indicator.gif" alt="*"/> Ładowanie</p>
+            <p><img src="/static/img/indicator.gif" alt="*"/> {% trans "Loading" %}</p>
         </div>
     </div>
 {% endblock %}
\ No newline at end of file
index aa273c8..e96320e 100644 (file)
@@ -1,7 +1,7 @@
 {% load i18n %}
 {% load catalogue_tags %}
 {% if one_tag %}
-    <p>Zobacz całą kategorię <a href="{% catalogue_url one_tag %}">{{ one_tag }}</a></p>
+    <p>{% trans "See full category" %} <a href="{% catalogue_url one_tag %}">{{ one_tag }}</a></p>
 {% else %}
     <ul>
         {% for tag in tags %}
index d36fb1d..230d8ed 100644 (file)
     
     {% if shelf_is_set and not object_list %}
     <div id="books-list">
-        <h2>Twoja półka jest pusta</h2>
-        <p>Możesz wrzucić książkę na półkę, wchodząc na stronę danej lektury i klikając na przycisk „Na półkę!”.</p>
+        <h2>{% trans "Your shelf is empty" %}</h2>
+        <p>{% trans "You can put a book on a shelf by entering page of the reading and clicking 'Put on the shelf'." %}</p>
     </div>
-       {% else
     {% else %}
     {% autopaginate object_list 10 %}
     <div id="books-list">
                 {{ last_tag.description|safe }}
             </div>
             <div class="clearboth"></div>
-            <div id="toggle-description"><p>Zwiń opis ▲</p></div>
+            <div id="toggle-description"><p>{% trans "Toggle description" %} ▲</p></div>
         {% endif %}
         {% if shelf_is_set %}
             <a id="download-shelf" href="{% url download_shelf last_tag.slug %}">
-                Pobierz wszystkie książki z tej półki
+                {% trans "Download all books from this shelf" %}
             </a>
             <div id="download-shelf-menu" style="display:none;">
                 <form action="{% url download_shelf last_tag.slug %}" method="get" accept-charset="utf-8" id="download-formats-form" data-formats-feed="{% url shelf_book_formats last_tag.slug %}">
-                    <p>Wybierz formaty książek, które chcesz pobrać:</p>
-                    <li data-format="pdf"><label for="id_formats_2"><input type="checkbox" name="formats" value="pdf" id="id_formats_2" /> PDF</label> <em><strong>do czytania</strong> i drukowania przy pomocy <a href="http://get.adobe.com/reader/">Adobe Reader</a></em></li>
-                    <li data-format="odt"><label for="id_formats_3"><input type="checkbox" name="formats" value="odt" id="id_formats_3" /> ODT</label> <em><strong>do czytania</strong> i edytowania przy pomocy <a href="http://pl.openoffice.org/">OpenOffice.org</a></em></li>
-                    <li data-format="txt"><label for="id_formats_4"><input type="checkbox" name="formats" value="txt" id="id_formats_4" /> TXT</label> <em><strong>do czytania</strong> na małych ekranach, np. na komórce</em></li>
-                    <li data-format="mp3"><label for="id_formats_0"><input type="checkbox" name="formats" value="mp3" id="id_formats_0" /> MP3</label> <em><strong>do słuchania</strong> w ulubionym odtwarzaczu MP3</em></li>
-                    <li data-format="ogg"><label for="id_formats_1"><input type="checkbox" name="formats" value="ogg" id="id_formats_1" /> Ogg Vorbis</label> <em><strong>do słuchania</strong> &mdash; otwarty format <a href="http://www.vorbis.com/">Fundacji Xiph.Org</a></em></li>
-                    <li id="download-formats-form-submit-li"><label><input type="submit" name="submit" value="Pobierz" id="download-formats-form-submit" disabled="disabled" />&nbsp;<img src="/static/img/indicator.gif" /></label> <span id="updating-formats">Uaktualniam listę formatów książek na półce.</span><span id="formats-updated" style="display:none;">lub <a href="#" id="download-formats-form-cancel">anuluj</a></span></li>
+                    <p>{% trans "Choose books' which you want to download:" %}</p>
+                    <li data-format="pdf"><label for="id_formats_2"><input type="checkbox" name="formats" value="pdf" id="id_formats_2" /> PDF</label> <em><strong>{% trans "for reading" %}</strong> {% trans "and printing using" %} <a href="http://get.adobe.com/reader/">Adobe Reader</a></em></li>
+                    <li data-format="odt"><label for="id_formats_3"><input type="checkbox" name="formats" value="odt" id="id_formats_3" /> ODT</label> <em><strong>{% trans "for reading" %}</strong> {% trans "and editing using" %} <a href="http://pl.openoffice.org/">OpenOffice.org</a></em></li>
+                    <li data-format="txt"><label for="id_formats_4"><input type="checkbox" name="formats" value="txt" id="id_formats_4" /> TXT</label> <em><strong>{% trans "for reading" %}</strong> {% trans "on small displays, for example mobile phones" %}</em></li>
+                    <li data-format="mp3"><label for="id_formats_0"><input type="checkbox" name="formats" value="mp3" id="id_formats_0" /> MP3</label> <em><strong>{% trans "for listening" %}</strong> {% trans "on favourite MP3 player" %}</em></li>
+                    <li data-format="ogg"><label for="id_formats_1"><input type="checkbox" name="formats" value="ogg" id="id_formats_1" /> Ogg Vorbis</label> <em><strong>{% trans "for listening" %}</strong> &mdash; {% trans "open format" %} <a href="http://www.vorbis.com/">{% trans "Xiph.org Foundation" %}</a></em></li>
+                    <li id="download-formats-form-submit-li"><label><input type="submit" name="submit" value="{% trans "Download" %}" id="download-formats-form-submit" disabled="disabled" />&nbsp;<img src="/static/img/indicator.gif" /></label> <span id="updating-formats">{% trans "Updating list of books' formats on the shelf" %}</span><span id="formats-updated" style="display:none;">{% trans "or" %} <a href="#" id="download-formats-form-cancel">{% trans "cancel" %}</a></span></li>
                     <div class="clearboth"></div>
                 </form>
             </div>
         {% endif %}
         {% if last_tag.gazeta_link %}
         <p><a href="{{ last_tag.gazeta_link }}">
-            {% ifequal last_tag.category "author" %}Przeczytaj omówienia utworów autora w serwisie Lektury.Gazeta.pl{% endifequal %}
-            {% ifequal last_tag.category "epoch"  %}Przeczytaj omówienia z epoki {{ last_tag }} w serwisie Lektury.Gazeta.pl{% endifequal %}
+            {% ifequal last_tag.category "author" %}
+                               {% trans "Read work's study of this author on Lektury.Gazeta.pl" %}
+                       {% endifequal %}
+            {% ifequal last_tag.category "epoch" %}
+                               {% trans "Read study of epoch" %} {{ last_tag }} {% trans "on Lektury.Gazeta.pl" %}
+                       {% endifequal %}
         </a></p>
         {% endif %}
         {% if last_tag.wiki_link %}
         <p><a href="{{ last_tag.wiki_link }}">
-            {% ifequal last_tag.category "author" %}Przeczytaj artykuł o autorze w Wikipedii{% endifequal %}
-            {% ifequal last_tag.category "epoch"  %}Przeczytaj artykuł o epoce {{ last_tag }} w Wikipedii{% endifequal %}
+            {% ifequal last_tag.category "author" %}
+                               {% trans "Read article about this author on Wikipedia" %}
+                       {% endifequal %}
+            {% ifequal last_tag.category "epoch"  %}
+                               {% trans "Read article about epoch" %} {{ last_tag }} {% trans "on Wikipedia" %}
+                       {% endifequal %}
         </a></p>
         {% endif %}
 
@@ -62,7 +69,7 @@
             {% for book in object_list %}
                 <li>
                     {% if user_is_owner %}
-                        <a href="{% url remove_from_shelf last_tag.slug book.slug %}" class="remove-from-shelf">Usuń</a>
+                        <a href="{% url remove_from_shelf last_tag.slug book.slug %}" class="remove-from-shelf">{% trans "Delete" %}</a>
                     {% endif %}
                     {{ book.short_html }}</li>
             {% endfor %}
         {% else %}
                        {% if only_author %}
                    {% if last_tag.alive %}
-                                       Dzieła tego autora objęte są prawem autorskim.
-                               {% else %}{% comment %} Nie żyje {% endcomment %}
+                                       {% trans "This author's works are copyrighted." %}
+                               {% else %}{% comment %} Is dead {% endcomment %}
                    {% if last_tag.in_pd %}
-                           Dzieła tego autora znajdują się w domenie publicznej
-                                               i niedługo zostaną opublikowane w szkolnej bibliotece
-                                               internetowej Wolne Lektury. 
-                       {% else %}{% comment %} Nie żyje, ale jeszcze nie w PD {% endcomment %}
+                                               {% trans "This author's works are in public domain and will be published on Internet school library of Wolne Lektury soon." %} 
+                       {% else %}{% comment %} Is dead, but not yet in public domain {% endcomment %}
                        <div>
-                               <p>Dzieła tego autora przejdą do zasobów domeny
-                                                       publicznej i będą mogły być publikowane bez
-                                                       żadnych ograniczeń za:</p>
+                               <p>{% trans "This author's works will become part of public domain and will be allowed to be published without restrictions in:" %}</p>
                                                        {% include "catalogue/pd_counter.html" %}
                                                </div>
                        {% endif %}
                 {% endif %}
                        {% else %}
-                           Nie znaleziono żadnych utworów.
+                           {% trans "No works of this author found." %}
                        {% endif %}
             {% include "info/join_us.html" %}
         {% endif %}
         {% paginate %}
     </div>
        {% if object_list %}
-       {% comment %} Jeśli nic nie znaleźliśmy, to i po prawej stronie nic nie będzie {% endcomment %}
+       {% comment %} If we didn't find anything there will be nothing on the right side as well {% endcomment %}
     <div id="tags-list">
         <div id="categories-list">
             {% if categories.author %}
-                <h2>Autorzy</h2>
+                <h2>{% trans "Authors" %}</h2>
                 {% tag_list categories.author tags %}
             {% endif %}
             {% if categories.kind %}
-                <h2>Rodzaje</h2>
+                <h2>{% trans "Kinds" %}</h2>
                 {% tag_list categories.kind tags %}
             {% endif %}
             {% if categories.genre %}
-                <h2>Gatunki literackie</h2>
+                <h2>{% trans "Genres" %}</h2>
                 {% tag_list categories.genre tags %}
             {% endif %}
             {% if categories.epoch %}
-                <h2>Epoki</h2>
+                <h2>{% trans "Epochs" %}</h2>
                 {% tag_list categories.epoch tags %}
             {% endif %}        
         </div>
         <div id="themes-list">
             {% if categories.theme %}
-                <h2>Motywy</h2>
+                <h2>{% trans "Themes" %}</h2>
                 {% tag_list categories.theme tags %}
             {% endif %}
         </div>
        {% endif %}
     {% endif %}
     <div id="set-window">
-        <div class="header"><a href="#" class="jqmClose">Zamknij</a></div>
+        <div class="header"><a href="#" class="jqmClose">{% trans "Close" %}</a></div>
         <div class="target">
-            <p><img src="/static/img/indicator.gif" alt="*"/> Ładowanie</p>
+            <p><img src="/static/img/indicator.gif" alt="*"/> {% trans "Loading" %}</p>
         </div>
     </div>
 {% endblock %}
\ No newline at end of file
index cd5b861..28c1222 100644 (file)
@@ -1,17 +1,17 @@
 {% load i18n %}
-<h2>Twoje półki z lekturami</h2>
+<h2>{% trans "Your shelves with books" %}</h2>
 {% if shelves %}
 <ul class="shelf-list">
 {% for shelf in shelves %}
-    <li><a href="{% url delete_shelf shelf.slug %}" class="delete-shelf">usuń</a> <a href="{{ shelf.get_absolute_url }}" class="visit-shelf">{{ shelf.name }} ({{ shelf.book_count }})</a></li>
+    <li><a href="{% url delete_shelf shelf.slug %}" class="delete-shelf">{% trans "remove" %}</a> <a href="{{ shelf.get_absolute_url }}" class="visit-shelf">{{ shelf.name }} ({{ shelf.book_count }})</a></li>
 {% endfor %}
 </ul>
 {% else %}
-<p>Nie posiadasz żadnych półek. Jeśli chcesz, możesz utworzyć półkę poniżej.</p>
+<p>{% trans "You do not own any shelves. You can create one below if you want to" %}.</p>
 {% endif %}
 <hr />
 <form action="{% url catalogue.views.new_set %}" method="post" accept-charset="utf-8" class="cuteform">
 <ol>
-    <li>{{ new_set_form.name }} <input type="submit" value="Utwórz półkę"/></li>
+    <li>{{ new_set_form.name }} <input type="submit" value="{% trans "Create shelf" %}"/></li>
 </ol>
 </form>
\ No newline at end of file
index 7c6406c..afc3d69 100644 (file)
@@ -6,7 +6,7 @@
 {% block body %}
     <h1>{{ object.title }}</h1>
     <form action="{% url search %}" method="GET" accept-charset="utf-8" id="search-form">
-        <p>{{ form.q }} <input type="submit" value="{% trans "Szukaj" %}" /> <strong>{% trans "or" %}</strong> <a href="{% url lessons_document_list %}">{% trans "return to list of materials" %}</a></p>
+        <p>{{ form.q }} <input type="submit" value="{% trans "Search" %}" /> <strong>{% trans "or" %}</strong> <a href="{% url lessons_document_list %}">{% trans "return to list of materials" %}</a></p>
     </form>
     
     <div id="document-detail">