diff --git a/resources/content_server/browse/browse.html b/resources/content_server/browse/browse.html
index ef312334d9..6d4c79c4c9 100644
--- a/resources/content_server/browse/browse.html
+++ b/resources/content_server/browse/browse.html
@@ -4,7 +4,7 @@
- ..:: calibre library ::.. {title}
+ ..:: calibre {library} ::.. {title}
@@ -41,7 +41,7 @@
@@ -80,7 +80,7 @@
diff --git a/resources/images/news/siol.png b/resources/images/news/siol.png
new file mode 100644
index 0000000000..e04283474b
Binary files /dev/null and b/resources/images/news/siol.png differ
diff --git a/resources/recipes/diario_sport.recipe b/resources/recipes/diario_sport.recipe
new file mode 100644
index 0000000000..8c7181098b
--- /dev/null
+++ b/resources/recipes/diario_sport.recipe
@@ -0,0 +1,42 @@
+from calibre.web.feeds.news import BasicNewsRecipe
+
+class DiarioSport(BasicNewsRecipe):
+ title = u'Diario Sport'
+ oldest_article = 2
+ max_articles_per_feed = 75
+ __author__ = 'Jefferson Frantz'
+ description = 'Todas las noticias del Barça y del mundo del deporte en general'
+ timefmt = ' [%d %b, %Y]'
+ language = 'es'
+ no_stylesheets = True
+
+ feeds = [(u'Sport', u'http://feeds.feedburner.com/sport/ultimahora')]
+
+ extra_css = '''
+ h2{font-family: serif; font-size: small; font-weight: bold; color: #000000; text-align: justify}
+ '''
+
+ keep_only_tags = [dict(name='div', attrs={'id':['noticiasMedio']})]
+
+ remove_tags = [
+ dict(name=['object','link','script','ul'])
+ ,dict(name='div', attrs={'id':['scrAdSense','herramientas2','participacion','participacion2','bloque1resultados','bloque2resultados','cont_vinyetesAnt','tinta','noticiasSuperior','cintillopublicidad2']})
+ ,dict(name='p', attrs={'class':['masinformacion','hora']})
+ ,dict(name='a', attrs={'class':["'link'"]})
+ ,dict(name='div', attrs={'class':['addthis_toolbox addthis_default_style','firma','pretitularnoticia']})
+ ,dict(name='form', attrs={'id':['formularioDeBusquedaAvanzada']})
+ ]
+
+ def preprocess_html(self, soup):
+ for item in soup.findAll(style=True):
+ del item['style']
+ return soup
+
+
+ def postprocess_html(self, soup, first_fetch):
+ img = soup.find('img',src='/img/videos/mascaravideo.png')
+ if not img is None:
+ img.extract()
+
+ return soup
+
diff --git a/resources/recipes/scprint.recipe b/resources/recipes/scprint.recipe
new file mode 100644
index 0000000000..d9ce70f7a2
--- /dev/null
+++ b/resources/recipes/scprint.recipe
@@ -0,0 +1,73 @@
+from calibre.web.feeds.recipes import BasicNewsRecipe, LoginFailed
+
+class SCPrintMagazine(BasicNewsRecipe):
+ title = u'SC Print Magazine'
+ __author__ = u'Tony Maro'
+ description = u'Last print version of the data security magazine'
+ INDEX = "http://www.scmagazineus.com/issuearchive/"
+ no_stylesheets = True
+ language = 'en'
+ keep_only_tags = [dict(id=['article','review'])]
+ remove_tags = [dict(id=['articlePrintTools','reviewBodyColumn'])]
+ LOG_IN = 'http://www.scmagazineus.com/login/'
+ tags = 'News,SC Magazine'
+ needs_subscription = True
+
+ def parse_index(self):
+ articles = []
+ issuelink = printsections = None
+
+ soup = self.index_to_soup(self.INDEX)
+ sectit = soup.find('div', attrs={'class':'issueArchiveItem'})
+ if sectit is not None:
+ linkt = sectit.find('a')
+ issuelink = linkt['href']
+ imgt = sectit.find('img')
+ self.cover_url = imgt['src']
+
+ if issuelink is not None:
+ issue = self.index_to_soup(issuelink)
+ if issue is not None:
+ printsections = issue.findAll('div',attrs={'class':'PrintSection'})
+ if printsections is not None:
+ for printsection in printsections:
+ onesection = []
+ sectiontitle = printsection.find('h3').contents[0]
+ articlesec = printsection.findAll('div',attrs={'class':'IssueArchiveFormat'})
+ if articlesec is not None:
+ ''' got articles '''
+ for onearticle in articlesec:
+ ''' process one article '''
+ arttitlet = onearticle.find('h3')
+ if arttitlet is not None:
+ mylink = arttitlet.find('a')
+ if mylink is not None:
+ if mylink.has_key('title'):
+ arttitle = mylink['title']
+ else:
+ arttitle = 'unknown'
+ if mylink.has_key('href'):
+ artlink = mylink['href']
+ artlink = artlink.replace("/article","/printarticle")
+ artlink = artlink.replace("/review","/printreview")
+ deck = onearticle.find('div',attrs={'class':'deck'})
+ if deck is not None:
+ deck = deck.contents[0]
+ onesection.append({'title':arttitle, 'url':artlink, 'description':deck,'date':''})
+ articles.append((sectiontitle, onesection))
+
+ return articles
+
+ def get_browser(self):
+ br = BasicNewsRecipe.get_browser(self)
+ br.open(self.LOG_IN)
+ br.select_form(name='aspnetForm')
+ br['ctl00$ctl00$cphAllPageContent$cphMainContent$SubscriberEasyLoginView1$txtEmail'] = self.username
+ br['ctl00$ctl00$cphAllPageContent$cphMainContent$SubscriberEasyLoginView1$txtPassword'] = self.password
+ raw = br.submit("ctl00$ctl00$cphAllPageContent$cphMainContent$SubscriberEasyLoginView1$btnLogin").read()
+ if 'Logout' not in raw:
+ raise LoginFailed(
+ _('Failed to log in, check your username and password for'
+ ' the calibre Periodicals service.'))
+ return br
+
diff --git a/resources/recipes/siol.recipe b/resources/recipes/siol.recipe
new file mode 100644
index 0000000000..2680c1f1e9
--- /dev/null
+++ b/resources/recipes/siol.recipe
@@ -0,0 +1,55 @@
+# coding: utf-8
+__license__ = 'GPL v3'
+__copyright__ = '2010, BlonG'
+'''
+www.siol.si
+'''
+from calibre.web.feeds.news import BasicNewsRecipe
+
+class Siol(BasicNewsRecipe):
+ title = u'Siol.net'
+ __author__ = u'BlonG'
+ description = "Multimedijski portal z aktualnimi vsebinami, intervjuji, komentarji iz Slovenije in sveta, sportal, trendi, avtomoto, blogos"
+ oldest_article = 3
+ max_articles_per_feed = 20
+ no_stylesheets = True
+ use_embedded_content = False
+ language = 'sl'
+
+ cover_url = 'http://farm4.static.flickr.com/3540/3401820496_c771550fe6.jpg'
+
+ extra_css = '''
+ h1{font-family:Arial,Helvetica,sans-serif; font-weight:bold;font-size:large;}
+ h2{font-family:Arial,Helvetica,sans-serif; font-weight:bold;font-size:large;}
+ p{font-family:Arial,Helvetica,sans-serif;font-size:small;}
+ body{font-family:Helvetica,Arial,sans-serif;font-size:small;}
+ '''
+
+ keep_only_tags = [
+ dict(name='div', attrs={'id':'idContent'}),
+ ]
+
+ remove_tags = [
+ dict(name='span', attrs={'class':'com1'}),
+ dict(name='div', attrs={'class':'relation'}),
+ dict(name='p', attrs={'class':'path'}),
+ dict(name='div', attrs={'class':'clear_r'}),
+ dict(name='div', attrs={'id':'appendix'}),
+ dict(name='div', attrs={'id':'rail'}),
+ dict(name='div', attrs={'id':'div_comments'}),
+ dict(name='div', attrs={'class':'thumbs'}),
+ ]
+
+ feeds = [
+ (u'Slovenija', u'http://www.siol.net/rss.aspx?path=Slovenija')
+ ,(u'Lokalne novice', u'http://www.siol.net/rss.aspx?path=Slovenija/Lokalne_novice')
+ ,(u'EU', u'http://www.siol.net/rss.aspx?path=EU')
+ ,(u'Svet', u'http://www.siol.net/rss.aspx?path=Svet')
+ ,(u'Gospodarstvo', u'http://www.siol.net/rss.aspx?path=Gospodarstvo')
+ ,(u'Sportal', u'http://www.siol.net/rss.aspx?path=Sportal')
+ ,(u'Trendi', u'http://www.siol.net/rss.aspx?path=Trendi')
+ ,(u'Avtomoto', u'http://www.siol.net/rss.aspx?path=Avtomoto')
+ ,(u'Tehnologija', u'http://www.siol.net/rss.aspx?path=Tehnologija')
+ ,(u'TV / Film', u'http://www.siol.net/rss.aspx?path=TV')
+ ]
+
diff --git a/setup/installer/__init__.py b/setup/installer/__init__.py
index 9b1f80f54b..c25334dbe4 100644
--- a/setup/installer/__init__.py
+++ b/setup/installer/__init__.py
@@ -49,7 +49,6 @@ class Push(Command):
print '\n\nPushing to:', host, '\n'
threads.append(Thread(target=subprocess.check_call, args=(rcmd,)))
threads[-1].start()
- subprocess.check_call(rcmd)
for thread in threads:
thread.join()
diff --git a/src/calibre/gui2/dialogs/book_info.py b/src/calibre/gui2/dialogs/book_info.py
index 70c70ddf96..4cbe0ace7f 100644
--- a/src/calibre/gui2/dialogs/book_info.py
+++ b/src/calibre/gui2/dialogs/book_info.py
@@ -5,8 +5,8 @@ __docformat__ = 'restructuredtext en'
import textwrap, os, re
-from PyQt4.QtCore import QCoreApplication, SIGNAL, QModelIndex, QTimer, Qt
-from PyQt4.QtGui import QDialog, QPixmap, QGraphicsScene, QIcon
+from PyQt4.Qt import QCoreApplication, SIGNAL, QModelIndex, QTimer, Qt, \
+ QDialog, QPixmap, QGraphicsScene, QIcon, QSize
from calibre.gui2.dialogs.book_info_ui import Ui_BookInfo
from calibre.gui2 import dynamic, open_local_file
@@ -20,6 +20,8 @@ class BookInfo(QDialog, Ui_BookInfo):
Ui_BookInfo.__init__(self)
self.setupUi(self)
self.cover_pixmap = None
+ self.comments.sizeHint = self.comments_size_hint
+
desktop = QCoreApplication.instance().desktop()
screen_height = desktop.availableGeometry().height() - 100
self.resize(self.size().width(), screen_height)
@@ -37,12 +39,16 @@ class BookInfo(QDialog, Ui_BookInfo):
self.fit_cover.stateChanged.connect(self.toggle_cover_fit)
self.cover.resizeEvent = self.cover_view_resized
+ def comments_size_hint(self):
+ return QSize(350, 350)
+
def toggle_cover_fit(self, state):
dynamic.set('book_info_dialog_fit_cover', self.fit_cover.isChecked())
self.resize_cover()
def cover_view_resized(self, event):
QTimer.singleShot(1, self.resize_cover)
+
def slave(self, current, previous):
row = current.row()
self.refresh(row)
diff --git a/src/calibre/gui2/dialogs/book_info.ui b/src/calibre/gui2/dialogs/book_info.ui
index d9ff87bcdd..7eb6ccd3d3 100644
--- a/src/calibre/gui2/dialogs/book_info.ui
+++ b/src/calibre/gui2/dialogs/book_info.ui
@@ -47,9 +47,15 @@
Comments
-
- -
+
+
-
+
+
+ 0
+ 0
+
+
350
diff --git a/src/calibre/library/server/browse.py b/src/calibre/library/server/browse.py
index 9530a34c73..5609416273 100644
--- a/src/calibre/library/server/browse.py
+++ b/src/calibre/library/server/browse.py
@@ -245,6 +245,9 @@ class BrowseServer(object):
ans = ans.replace('{sort_select_label}', xml(_('Sort by')+':'))
ans = ans.replace('{sort_cookie_name}', scn)
ans = ans.replace('{prefix}', self.opts.url_prefix)
+ ans = ans.replace('{library}', _('library'))
+ ans = ans.replace('{home}', _('home'))
+ ans = ans.replace('{Search}', _('Search'))
opts = ['' % (
'selected="selected" ' if k==sort else '',
xml(k), xml(n), ) for k, n in
diff --git a/src/calibre/translations/calibre.pot b/src/calibre/translations/calibre.pot
index 4e25612b5d..350cb14bca 100644
--- a/src/calibre/translations/calibre.pot
+++ b/src/calibre/translations/calibre.pot
@@ -5,8 +5,8 @@
msgid ""
msgstr ""
"Project-Id-Version: calibre 0.7.27\n"
-"POT-Creation-Date: 2010-11-05 15:17+MDT\n"
-"PO-Revision-Date: 2010-11-05 15:17+MDT\n"
+"POT-Creation-Date: 2010-11-06 09:35+MDT\n"
+"PO-Revision-Date: 2010-11-06 09:35+MDT\n"
"Last-Translator: Automatically generated\n"
"Language-Team: LANGUAGE\n"
"MIME-Version: 1.0\n"
@@ -1932,7 +1932,7 @@ msgstr ""
#: /home/kovid/work/calibre/src/calibre/gui2/library/models.py:313
#: /home/kovid/work/calibre/src/calibre/gui2/library/models.py:1127
#: /home/kovid/work/calibre/src/calibre/library/field_metadata.py:160
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:620
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:623
msgid "Tags"
msgstr ""
@@ -2299,7 +2299,7 @@ msgstr ""
#: /home/kovid/work/calibre/src/calibre/ebooks/oeb/transforms/jacket.py:159
#: /home/kovid/work/calibre/src/calibre/gui2/library/models.py:71
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:618
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:621
msgid "Rating"
msgstr ""
@@ -3570,7 +3570,7 @@ msgid "Click the show details button to see which ones."
msgstr ""
#: /home/kovid/work/calibre/src/calibre/gui2/actions/show_book_details.py:16
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:625
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:628
msgid "Show book details"
msgstr ""
@@ -3878,7 +3878,7 @@ msgstr ""
#: /home/kovid/work/calibre/src/calibre/gui2/book_details.py:25
#: /home/kovid/work/calibre/src/calibre/gui2/book_details.py:49
#: /home/kovid/work/calibre/src/calibre/gui2/book_details.py:58
-#: /home/kovid/work/calibre/src/calibre/gui2/book_details.py:402
+#: /home/kovid/work/calibre/src/calibre/gui2/book_details.py:403
#: /home/kovid/work/calibre/src/calibre/gui2/dialogs/book_info.py:119
#: /home/kovid/work/calibre/src/calibre/gui2/dialogs/book_info.py:120
#: /home/kovid/work/calibre/src/calibre/gui2/dialogs/book_info.py:121
@@ -3925,7 +3925,7 @@ msgstr ""
msgid "None"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/gui2/book_details.py:401
+#: /home/kovid/work/calibre/src/calibre/gui2/book_details.py:402
msgid "Double-click to open Book Details window"
msgstr ""
@@ -7601,7 +7601,7 @@ msgid "Successfully downloaded metadata for %d out of %d books"
msgstr ""
#: /home/kovid/work/calibre/src/calibre/gui2/metadata.py:287
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:624
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:627
msgid "Details"
msgstr ""
@@ -8581,6 +8581,7 @@ msgstr ""
#: /home/kovid/work/calibre/src/calibre/gui2/search_box.py:97
#: /home/kovid/work/calibre/src/calibre/gui2/search_box.py:270
#: /home/kovid/work/calibre/src/calibre/gui2/widgets.py:574
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:250
msgid "Search"
msgstr ""
@@ -10477,7 +10478,7 @@ msgid "Password to access your calibre library. Username is "
msgstr ""
#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:51
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:402
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:405
msgid "Loading, please wait"
msgstr ""
@@ -10522,70 +10523,78 @@ msgstr ""
msgid "Sort by"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:307
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:513
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:248
+msgid "library"
+msgstr ""
+
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:249
+msgid "home"
+msgstr ""
+
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:310
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:516
#: /home/kovid/work/calibre/src/calibre/library/server/opds.py:569
msgid "Newest"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:308
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:514
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:311
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:517
msgid "All books"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:341
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:344
msgid "Browse books by"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:346
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:349
msgid "Choose a category to browse by:"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:422
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:425
msgid "Browsing by"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:423
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:426
msgid "Up"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:544
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:547
msgid "in"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:547
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:550
msgid "Books in"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:599
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:602
msgid "Other formats"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:606
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:609
msgid "Read %s in the %s format"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:611
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:614
msgid "Get"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:626
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:629
msgid "Permalink"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:627
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:630
msgid "A permanent link to this book"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:638
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:641
msgid "This book has been deleted"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:722
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:725
msgid "in search"
msgstr ""
-#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:724
+#: /home/kovid/work/calibre/src/calibre/library/server/browse.py:727
msgid "Matching books"
msgstr ""