# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file '/work/a/ports/deskutils/calibre/work/calibre/src/calibre/gui2/main.ui'
#
# Created: Mon Feb 22 19:36:38 2010
#      by: PyQt4 UI code generator 4.7
#
# WARNING! All changes made in this file will be lost!

from PyQt4 import QtCore, QtGui

class Ui_MainWindow(object):
    def setupUi(self, MainWindow):
        MainWindow.setObjectName("MainWindow")
        MainWindow.resize(1012, 822)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(MainWindow.sizePolicy().hasHeightForWidth())
        MainWindow.setSizePolicy(sizePolicy)
        MainWindow.setContextMenuPolicy(QtCore.Qt.NoContextMenu)
        icon = QtGui.QIcon()
        icon.addPixmap(QtGui.QPixmap(I("library.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        MainWindow.setWindowIcon(icon)
        self.centralwidget = QtGui.QWidget(MainWindow)
        self.centralwidget.setObjectName("centralwidget")
        self.gridLayout = QtGui.QGridLayout(self.centralwidget)
        self.gridLayout.setObjectName("gridLayout")
        self.horizontalLayout_3 = QtGui.QHBoxLayout()
        self.horizontalLayout_3.setObjectName("horizontalLayout_3")
        self.location_view = LocationView(self.centralwidget)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.location_view.sizePolicy().hasHeightForWidth())
        self.location_view.setSizePolicy(sizePolicy)
        self.location_view.setMaximumSize(QtCore.QSize(16777215, 75))
        self.location_view.setMouseTracking(True)
        self.location_view.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
        self.location_view.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAsNeeded)
        self.location_view.setEditTriggers(QtGui.QAbstractItemView.NoEditTriggers)
        self.location_view.setTabKeyNavigation(True)
        self.location_view.setProperty("showDropIndicator", True)
        self.location_view.setSelectionMode(QtGui.QAbstractItemView.NoSelection)
        self.location_view.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
        self.location_view.setIconSize(QtCore.QSize(40, 40))
        self.location_view.setMovement(QtGui.QListView.Static)
        self.location_view.setFlow(QtGui.QListView.LeftToRight)
        self.location_view.setGridSize(QtCore.QSize(175, 90))
        self.location_view.setViewMode(QtGui.QListView.ListMode)
        self.location_view.setWordWrap(True)
        self.location_view.setObjectName("location_view")
        self.horizontalLayout_3.addWidget(self.location_view)
        self.donate_button = QtGui.QToolButton(self.centralwidget)
        self.donate_button.setCursor(QtCore.Qt.PointingHandCursor)
        icon1 = QtGui.QIcon()
        icon1.addPixmap(QtGui.QPixmap(I("donate.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.donate_button.setIcon(icon1)
        self.donate_button.setIconSize(QtCore.QSize(64, 64))
        self.donate_button.setAutoRaise(True)
        self.donate_button.setObjectName("donate_button")
        self.horizontalLayout_3.addWidget(self.donate_button)
        self.verticalLayout_3 = QtGui.QVBoxLayout()
        self.verticalLayout_3.setObjectName("verticalLayout_3")
        self.vanity = QtGui.QLabel(self.centralwidget)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.vanity.sizePolicy().hasHeightForWidth())
        self.vanity.setSizePolicy(sizePolicy)
        self.vanity.setMaximumSize(QtCore.QSize(16777215, 90))
        self.vanity.setTextFormat(QtCore.Qt.RichText)
        self.vanity.setOpenExternalLinks(True)
        self.vanity.setObjectName("vanity")
        self.verticalLayout_3.addWidget(self.vanity)
        self.horizontalLayout_3.addLayout(self.verticalLayout_3)
        self.gridLayout.addLayout(self.horizontalLayout_3, 0, 0, 1, 1)
        self.hboxlayout = QtGui.QHBoxLayout()
        self.hboxlayout.setSpacing(6)
        self.hboxlayout.setMargin(0)
        self.hboxlayout.setObjectName("hboxlayout")
        self.advanced_search_button = QtGui.QToolButton(self.centralwidget)
        icon2 = QtGui.QIcon()
        icon2.addPixmap(QtGui.QPixmap(I("search.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.advanced_search_button.setIcon(icon2)
        self.advanced_search_button.setObjectName("advanced_search_button")
        self.hboxlayout.addWidget(self.advanced_search_button)
        self.label = QtGui.QLabel(self.centralwidget)
        self.label.setObjectName("label")
        self.hboxlayout.addWidget(self.label)
        self.search = SearchBox2(self.centralwidget)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.search.sizePolicy().hasHeightForWidth())
        self.search.setSizePolicy(sizePolicy)
        self.search.setMaximumSize(QtCore.QSize(700, 16777215))
        self.search.setObjectName("search")
        self.hboxlayout.addWidget(self.search)
        self.clear_button = QtGui.QToolButton(self.centralwidget)
        icon3 = QtGui.QIcon()
        icon3.addPixmap(QtGui.QPixmap(I("clear_left.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.clear_button.setIcon(icon3)
        self.clear_button.setObjectName("clear_button")
        self.hboxlayout.addWidget(self.clear_button)
        self.gridLayout.addLayout(self.hboxlayout, 1, 0, 1, 1)
        self.stack = QtGui.QStackedWidget(self.centralwidget)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(100)
        sizePolicy.setVerticalStretch(100)
        sizePolicy.setHeightForWidth(self.stack.sizePolicy().hasHeightForWidth())
        self.stack.setSizePolicy(sizePolicy)
        self.stack.setObjectName("stack")
        self.library = QtGui.QWidget()
        self.library.setObjectName("library")
        self.verticalLayout_2 = QtGui.QVBoxLayout(self.library)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.horizontalLayout = QtGui.QHBoxLayout()
        self.horizontalLayout.setObjectName("horizontalLayout")
        self.verticalLayout = QtGui.QVBoxLayout()
        self.verticalLayout.setObjectName("verticalLayout")
        self.match_any = QtGui.QRadioButton(self.library)
        self.match_any.setChecked(False)
        self.match_any.setObjectName("match_any")
        self.verticalLayout.addWidget(self.match_any)
        self.match_all = QtGui.QRadioButton(self.library)
        self.match_all.setChecked(True)
        self.match_all.setObjectName("match_all")
        self.verticalLayout.addWidget(self.match_all)
        self.popularity = QtGui.QCheckBox(self.library)
        self.popularity.setObjectName("popularity")
        self.verticalLayout.addWidget(self.popularity)
        self.tags_view = TagsView(self.library)
        self.tags_view.setTabKeyNavigation(True)
        self.tags_view.setAlternatingRowColors(True)
        self.tags_view.setAnimated(True)
        self.tags_view.setHeaderHidden(True)
        self.tags_view.setObjectName("tags_view")
        self.verticalLayout.addWidget(self.tags_view)
        self.horizontalLayout.addLayout(self.verticalLayout)
        self.library_view = BooksView(self.library)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(100)
        sizePolicy.setVerticalStretch(10)
        sizePolicy.setHeightForWidth(self.library_view.sizePolicy().hasHeightForWidth())
        self.library_view.setSizePolicy(sizePolicy)
        self.library_view.setAcceptDrops(True)
        self.library_view.setDragEnabled(True)
        self.library_view.setDragDropOverwriteMode(False)
        self.library_view.setDragDropMode(QtGui.QAbstractItemView.DragDrop)
        self.library_view.setAlternatingRowColors(True)
        self.library_view.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
        self.library_view.setShowGrid(False)
        self.library_view.setWordWrap(False)
        self.library_view.setObjectName("library_view")
        self.horizontalLayout.addWidget(self.library_view)
        self.verticalLayout_2.addLayout(self.horizontalLayout)
        self.stack.addWidget(self.library)
        self.main_memory = QtGui.QWidget()
        self.main_memory.setObjectName("main_memory")
        self.gridlayout = QtGui.QGridLayout(self.main_memory)
        self.gridlayout.setObjectName("gridlayout")
        self.memory_view = DeviceBooksView(self.main_memory)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Expanding, QtGui.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(100)
        sizePolicy.setVerticalStretch(10)
        sizePolicy.setHeightForWidth(self.memory_view.sizePolicy().hasHeightForWidth())
        self.memory_view.setSizePolicy(sizePolicy)
        self.memory_view.setAcceptDrops(True)
        self.memory_view.setDragEnabled(True)
        self.memory_view.setDragDropOverwriteMode(False)
        self.memory_view.setDragDropMode(QtGui.QAbstractItemView.DragDrop)
        self.memory_view.setAlternatingRowColors(True)
        self.memory_view.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
        self.memory_view.setShowGrid(False)
        self.memory_view.setWordWrap(False)
        self.memory_view.setObjectName("memory_view")
        self.gridlayout.addWidget(self.memory_view, 0, 0, 1, 1)
        self.stack.addWidget(self.main_memory)
        self.card_a_memory = QtGui.QWidget()
        self.card_a_memory.setObjectName("card_a_memory")
        self.gridlayout1 = QtGui.QGridLayout(self.card_a_memory)
        self.gridlayout1.setObjectName("gridlayout1")
        self.card_a_view = DeviceBooksView(self.card_a_memory)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(10)
        sizePolicy.setVerticalStretch(10)
        sizePolicy.setHeightForWidth(self.card_a_view.sizePolicy().hasHeightForWidth())
        self.card_a_view.setSizePolicy(sizePolicy)
        self.card_a_view.setAcceptDrops(True)
        self.card_a_view.setDragEnabled(True)
        self.card_a_view.setDragDropOverwriteMode(False)
        self.card_a_view.setDragDropMode(QtGui.QAbstractItemView.DragDrop)
        self.card_a_view.setAlternatingRowColors(True)
        self.card_a_view.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
        self.card_a_view.setShowGrid(False)
        self.card_a_view.setWordWrap(False)
        self.card_a_view.setObjectName("card_a_view")
        self.gridlayout1.addWidget(self.card_a_view, 0, 0, 1, 1)
        self.stack.addWidget(self.card_a_memory)
        self.card_b_memory = QtGui.QWidget()
        self.card_b_memory.setObjectName("card_b_memory")
        self.gridlayout2 = QtGui.QGridLayout(self.card_b_memory)
        self.gridlayout2.setObjectName("gridlayout2")
        self.card_b_view = DeviceBooksView(self.card_b_memory)
        sizePolicy = QtGui.QSizePolicy(QtGui.QSizePolicy.Preferred, QtGui.QSizePolicy.Expanding)
        sizePolicy.setHorizontalStretch(10)
        sizePolicy.setVerticalStretch(10)
        sizePolicy.setHeightForWidth(self.card_b_view.sizePolicy().hasHeightForWidth())
        self.card_b_view.setSizePolicy(sizePolicy)
        self.card_b_view.setAcceptDrops(True)
        self.card_b_view.setDragEnabled(True)
        self.card_b_view.setDragDropOverwriteMode(False)
        self.card_b_view.setDragDropMode(QtGui.QAbstractItemView.DragDrop)
        self.card_b_view.setAlternatingRowColors(True)
        self.card_b_view.setSelectionBehavior(QtGui.QAbstractItemView.SelectRows)
        self.card_b_view.setShowGrid(False)
        self.card_b_view.setWordWrap(False)
        self.card_b_view.setObjectName("card_b_view")
        self.gridlayout2.addWidget(self.card_b_view, 0, 0, 1, 1)
        self.stack.addWidget(self.card_b_memory)
        self.gridLayout.addWidget(self.stack, 2, 0, 1, 1)
        MainWindow.setCentralWidget(self.centralwidget)
        self.tool_bar = QtGui.QToolBar(MainWindow)
        self.tool_bar.setMinimumSize(QtCore.QSize(0, 0))
        self.tool_bar.setContextMenuPolicy(QtCore.Qt.PreventContextMenu)
        self.tool_bar.setMovable(False)
        self.tool_bar.setOrientation(QtCore.Qt.Horizontal)
        self.tool_bar.setIconSize(QtCore.QSize(48, 48))
        self.tool_bar.setToolButtonStyle(QtCore.Qt.ToolButtonTextUnderIcon)
        self.tool_bar.setObjectName("tool_bar")
        MainWindow.addToolBar(QtCore.Qt.TopToolBarArea, self.tool_bar)
        self.statusBar = QtGui.QStatusBar(MainWindow)
        self.statusBar.setMouseTracking(True)
        self.statusBar.setObjectName("statusBar")
        MainWindow.setStatusBar(self.statusBar)
        self.action_add = QtGui.QAction(MainWindow)
        icon4 = QtGui.QIcon()
        icon4.addPixmap(QtGui.QPixmap(I("add_book.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_add.setIcon(icon4)
        self.action_add.setAutoRepeat(False)
        self.action_add.setObjectName("action_add")
        self.action_del = QtGui.QAction(MainWindow)
        icon5 = QtGui.QIcon()
        icon5.addPixmap(QtGui.QPixmap(I("trash.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_del.setIcon(icon5)
        self.action_del.setObjectName("action_del")
        self.action_edit = QtGui.QAction(MainWindow)
        icon6 = QtGui.QIcon()
        icon6.addPixmap(QtGui.QPixmap(I("edit_input.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_edit.setIcon(icon6)
        self.action_edit.setAutoRepeat(False)
        self.action_edit.setObjectName("action_edit")
        self.action_sync = QtGui.QAction(MainWindow)
        self.action_sync.setEnabled(False)
        icon7 = QtGui.QIcon()
        icon7.addPixmap(QtGui.QPixmap(I("sync.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_sync.setIcon(icon7)
        self.action_sync.setObjectName("action_sync")
        self.action_save = QtGui.QAction(MainWindow)
        icon8 = QtGui.QIcon()
        icon8.addPixmap(QtGui.QPixmap(I("save.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_save.setIcon(icon8)
        self.action_save.setObjectName("action_save")
        self.action_news = QtGui.QAction(MainWindow)
        icon9 = QtGui.QIcon()
        icon9.addPixmap(QtGui.QPixmap(I("news.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_news.setIcon(icon9)
        self.action_news.setObjectName("action_news")
        self.action_convert = QtGui.QAction(MainWindow)
        icon10 = QtGui.QIcon()
        icon10.addPixmap(QtGui.QPixmap(I("convert.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_convert.setIcon(icon10)
        self.action_convert.setObjectName("action_convert")
        self.action_view = QtGui.QAction(MainWindow)
        icon11 = QtGui.QIcon()
        icon11.addPixmap(QtGui.QPixmap(I("view.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_view.setIcon(icon11)
        self.action_view.setObjectName("action_view")
        self.action_open_containing_folder = QtGui.QAction(MainWindow)
        icon12 = QtGui.QIcon()
        icon12.addPixmap(QtGui.QPixmap(I("document_open.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_open_containing_folder.setIcon(icon12)
        self.action_open_containing_folder.setObjectName("action_open_containing_folder")
        self.action_show_book_details = QtGui.QAction(MainWindow)
        icon13 = QtGui.QIcon()
        icon13.addPixmap(QtGui.QPixmap(I("dialog_information.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_show_book_details.setIcon(icon13)
        self.action_show_book_details.setObjectName("action_show_book_details")
        self.action_books_by_same_author = QtGui.QAction(MainWindow)
        icon14 = QtGui.QIcon()
        icon14.addPixmap(QtGui.QPixmap(I("user_profile.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_books_by_same_author.setIcon(icon14)
        self.action_books_by_same_author.setObjectName("action_books_by_same_author")
        self.action_books_in_this_series = QtGui.QAction(MainWindow)
        icon15 = QtGui.QIcon()
        icon15.addPixmap(QtGui.QPixmap(I("books_in_series.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_books_in_this_series.setIcon(icon15)
        self.action_books_in_this_series.setObjectName("action_books_in_this_series")
        self.action_books_by_this_publisher = QtGui.QAction(MainWindow)
        icon16 = QtGui.QIcon()
        icon16.addPixmap(QtGui.QPixmap(I("publisher.png")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_books_by_this_publisher.setIcon(icon16)
        self.action_books_by_this_publisher.setObjectName("action_books_by_this_publisher")
        self.action_books_with_the_same_tags = QtGui.QAction(MainWindow)
        icon17 = QtGui.QIcon()
        icon17.addPixmap(QtGui.QPixmap(I("tags.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_books_with_the_same_tags.setIcon(icon17)
        self.action_books_with_the_same_tags.setObjectName("action_books_with_the_same_tags")
        self.action_preferences = QtGui.QAction(MainWindow)
        icon18 = QtGui.QIcon()
        icon18.addPixmap(QtGui.QPixmap(I("config.svg")), QtGui.QIcon.Normal, QtGui.QIcon.Off)
        self.action_preferences.setIcon(icon18)
        self.action_preferences.setObjectName("action_preferences")
        self.tool_bar.addAction(self.action_add)
        self.tool_bar.addAction(self.action_edit)
        self.tool_bar.addAction(self.action_convert)
        self.tool_bar.addAction(self.action_view)
        self.tool_bar.addAction(self.action_news)
        self.tool_bar.addSeparator()
        self.tool_bar.addAction(self.action_sync)
        self.tool_bar.addAction(self.action_save)
        self.tool_bar.addAction(self.action_del)
        self.tool_bar.addSeparator()
        self.tool_bar.addAction(self.action_preferences)
        self.label.setBuddy(self.search)

        self.retranslateUi(MainWindow)
        self.stack.setCurrentIndex(3)
        QtCore.QMetaObject.connectSlotsByName(MainWindow)

    def retranslateUi(self, MainWindow):
        MainWindow.setWindowTitle(_("calibre"))
        self.donate_button.setText(_("..."))
        self.advanced_search_button.setToolTip(_("Advanced search"))
        self.advanced_search_button.setText(_("..."))
        self.advanced_search_button.setShortcut(_("Alt+S"))
        self.label.setText(_("&Search:"))
        self.search.setToolTip(_("<p>Search the list of books by title, author, publisher, tags, comments, etc.<br><br>Words separated by spaces are ANDed"))
        self.search.setWhatsThis(_("<p>Search the list of books by title, author, publisher, tags, comments, etc.<br><br>Words separated by spaces are ANDed"))
        self.clear_button.setToolTip(_("Reset Quick Search"))
        self.clear_button.setText(_("..."))
        self.match_any.setText(_("Match any"))
        self.match_all.setText(_("Match all"))
        self.popularity.setText(_("Sort by &popularity"))
        self.action_add.setText(_("Add books"))
        self.action_add.setShortcut(_("A"))
        self.action_del.setText(_("Remove books"))
        self.action_del.setToolTip(_("Remove books"))
        self.action_del.setShortcut(_("Del"))
        self.action_edit.setText(_("Edit meta information"))
        self.action_edit.setShortcut(_("E"))
        self.action_sync.setText(_("Send to device"))
        self.action_save.setText(_("Save to disk"))
        self.action_save.setShortcut(_("S"))
        self.action_news.setText(_("Fetch news"))
        self.action_news.setShortcut(_("F"))
        self.action_convert.setText(_("Convert E-books"))
        self.action_convert.setShortcut(_("C"))
        self.action_view.setText(_("View"))
        self.action_view.setShortcut(_("V"))
        self.action_open_containing_folder.setText(_("Open containing folder"))
        self.action_show_book_details.setText(_("Show book details"))
        self.action_books_by_same_author.setText(_("Books by same author"))
        self.action_books_in_this_series.setText(_("Books in this series"))
        self.action_books_by_this_publisher.setText(_("Books by this publisher"))
        self.action_books_with_the_same_tags.setText(_("Books with the same tags"))
        self.action_preferences.setText(_("Preferences"))
        self.action_preferences.setToolTip(_("Configure calibre"))
        self.action_preferences.setShortcut(_("Ctrl+P"))

from calibre.gui2.widgets import LocationView
from calibre.gui2.tag_view import TagsView
from calibre.gui2.search_box import SearchBox2
from calibre.gui2.library import BooksView, DeviceBooksView

