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

# Form implementation generated from reading ui file '/home/detlev/Development/Python/Eric/eric3_6/eric3/DocumentationTools/EricdocConfigForm.ui'
#
# Created: Do Dez 30 14:12:45 2004
#      by: The PyQt User Interface Compiler (pyuic) snapshot-20041229
#
# WARNING! All changes made in this file will be lost!


import sys
from qt import *


class EricdocConfigForm(QDialog):
    def __init__(self,parent = None,name = None,modal = 0,fl = 0):
        QDialog.__init__(self,parent,name,modal,fl)

        if not name:
            self.setName("EricdocConfigForm")


        EricdocConfigFormLayout = QVBoxLayout(self,6,6,"EricdocConfigFormLayout")

        layout14 = QGridLayout(None,1,1,0,6,"layout14")

        self.textLabel1 = QLabel(self,"textLabel1")

        layout14.addWidget(self.textLabel1,1,0)

        self.prefixEdit = QLineEdit(self,"prefixEdit")

        layout14.addWidget(self.prefixEdit,1,1)

        self.outputDirEdit = QLineEdit(self,"outputDirEdit")

        layout14.addWidget(self.outputDirEdit,0,1)

        self.outputDirButton = QPushButton(self,"outputDirButton")
        self.outputDirButton.setFocusPolicy(QPushButton.NoFocus)

        layout14.addWidget(self.outputDirButton,0,2)

        self.TextLabel6 = QLabel(self,"TextLabel6")

        layout14.addWidget(self.TextLabel6,0,0)
        EricdocConfigFormLayout.addLayout(layout14)

        layout4 = QHBoxLayout(None,0,6,"layout4")

        self.recursionCheckBox = QCheckBox(self,"recursionCheckBox")
        layout4.addWidget(self.recursionCheckBox)

        self.noindexCheckBox = QCheckBox(self,"noindexCheckBox")
        layout4.addWidget(self.noindexCheckBox)
        spacer13 = QSpacerItem(145,20,QSizePolicy.Expanding,QSizePolicy.Minimum)
        layout4.addItem(spacer13)
        EricdocConfigFormLayout.addLayout(layout4)

        layout5 = QHBoxLayout(None,0,6,"layout5")

        self.noemptyCheckBox = QCheckBox(self,"noemptyCheckBox")
        layout5.addWidget(self.noemptyCheckBox)
        spacer4 = QSpacerItem(40,20,QSizePolicy.Expanding,QSizePolicy.Minimum)
        layout5.addItem(spacer4)
        EricdocConfigFormLayout.addLayout(layout5)

        self.GroupBox3 = QGroupBox(self,"GroupBox3")
        self.GroupBox3.setColumnLayout(0,Qt.Vertical)
        self.GroupBox3.layout().setSpacing(6)
        self.GroupBox3.layout().setMargin(6)
        GroupBox3Layout = QGridLayout(self.GroupBox3.layout())
        GroupBox3Layout.setAlignment(Qt.AlignTop)

        self.ignoreDirButton = QPushButton(self.GroupBox3,"ignoreDirButton")
        self.ignoreDirButton.setFocusPolicy(QPushButton.NoFocus)

        GroupBox3Layout.addWidget(self.ignoreDirButton,1,3)

        self.deleteButton = QPushButton(self.GroupBox3,"deleteButton")

        GroupBox3Layout.addWidget(self.deleteButton,1,0)

        self.ignoreDirEdit = QLineEdit(self.GroupBox3,"ignoreDirEdit")

        GroupBox3Layout.addWidget(self.ignoreDirEdit,1,2)

        self.addButton = QPushButton(self.GroupBox3,"addButton")

        GroupBox3Layout.addWidget(self.addButton,1,1)

        self.ignoreDirsListBox = QListBox(self.GroupBox3,"ignoreDirsListBox")

        GroupBox3Layout.addMultiCellWidget(self.ignoreDirsListBox,0,0,0,3)
        EricdocConfigFormLayout.addWidget(self.GroupBox3)

        Layout1 = QHBoxLayout(None,0,6,"Layout1")
        Spacer1 = QSpacerItem(30,0,QSizePolicy.Expanding,QSizePolicy.Minimum)
        Layout1.addItem(Spacer1)

        self.okButton = QPushButton(self,"okButton")
        self.okButton.setDefault(1)
        Layout1.addWidget(self.okButton)

        self.cancelButton = QPushButton(self,"cancelButton")
        Layout1.addWidget(self.cancelButton)
        Spacer2 = QSpacerItem(30,0,QSizePolicy.Expanding,QSizePolicy.Minimum)
        Layout1.addItem(Spacer2)
        EricdocConfigFormLayout.addLayout(Layout1)

        self.languageChange()

        self.resize(QSize(506,486).expandedTo(self.minimumSizeHint()))
        self.clearWState(Qt.WState_Polished)

        self.connect(self.okButton,SIGNAL("clicked()"),self.accept)
        self.connect(self.cancelButton,SIGNAL("clicked()"),self.reject)
        self.connect(self.outputDirButton,SIGNAL("clicked()"),self.handleOutputDir)
        self.connect(self.ignoreDirButton,SIGNAL("clicked()"),self.handleIgnoreDir)
        self.connect(self.addButton,SIGNAL("clicked()"),self.handleIgnoreDirAdd)
        self.connect(self.deleteButton,SIGNAL("clicked()"),self.handleIgnoreDirDelete)

        self.setTabOrder(self.outputDirEdit,self.prefixEdit)
        self.setTabOrder(self.prefixEdit,self.recursionCheckBox)
        self.setTabOrder(self.recursionCheckBox,self.noindexCheckBox)
        self.setTabOrder(self.noindexCheckBox,self.noemptyCheckBox)
        self.setTabOrder(self.noemptyCheckBox,self.ignoreDirsListBox)
        self.setTabOrder(self.ignoreDirsListBox,self.ignoreDirEdit)
        self.setTabOrder(self.ignoreDirEdit,self.addButton)
        self.setTabOrder(self.addButton,self.deleteButton)
        self.setTabOrder(self.deleteButton,self.okButton)
        self.setTabOrder(self.okButton,self.cancelButton)


    def languageChange(self):
        self.setCaption(self.__tr("Ericdoc Configuration"))
        self.textLabel1.setText(self.__tr("Filename Prefix:"))
        QToolTip.add(self.prefixEdit,self.__tr("Enter a prefix to be prepended to the base names of generated files"))
        QToolTip.add(self.outputDirEdit,self.__tr("Enter an output directory"))
        self.outputDirButton.setText(self.__tr("..."))
        QToolTip.add(self.outputDirButton,self.__tr("Press to open a directory selection dialog"))
        self.TextLabel6.setText(self.__tr("Output Directory:"))
        self.recursionCheckBox.setText(self.__tr("Recurse into subdirectories"))
        QToolTip.add(self.recursionCheckBox,self.__tr("Select to recurse into subdirectories"))
        self.noindexCheckBox.setText(self.__tr("Don't generate index files"))
        QToolTip.add(self.noindexCheckBox,self.__tr("Select, if no index files should be generated"))
        self.noemptyCheckBox.setText(self.__tr("Don't include empty modules"))
        QToolTip.add(self.noemptyCheckBox,self.__tr("Select to exclude empty modules"))
        self.GroupBox3.setTitle(self.__tr("Exclude Directories"))
        self.ignoreDirButton.setText(self.__tr("..."))
        QToolTip.add(self.ignoreDirButton,self.__tr("Press to open a directory selection dialog"))
        self.deleteButton.setText(self.__tr("Delete"))
        QToolTip.add(self.deleteButton,self.__tr("Press to delete the selcted directory from the list"))
        QToolTip.add(self.ignoreDirEdit,self.__tr("Enter a directory basename to be ignored"))
        self.addButton.setText(self.__tr("Add"))
        QToolTip.add(self.addButton,self.__tr("Press to add the entered directory to the list"))
        QToolTip.add(self.ignoreDirsListBox,self.__tr("List of directory basenames to be ignored"))
        self.okButton.setText(self.__tr("&OK"))
        self.okButton.setAccel(self.__tr("Alt+O"))
        self.cancelButton.setText(self.__tr("&Cancel"))


    def handleOutputDir(self):
        print "EricdocConfigForm.handleOutputDir(): Not implemented yet"

    def handleIgnoreDir(self):
        print "EricdocConfigForm.handleIgnoreDir(): Not implemented yet"

    def handleIgnoreDirAdd(self):
        print "EricdocConfigForm.handleIgnoreDirAdd(): Not implemented yet"

    def handleIgnoreDirDelete(self):
        print "EricdocConfigForm.handleIgnoreDirDelete(): Not implemented yet"

    def __tr(self,s,c = None):
        return qApp.translate("EricdocConfigForm",s,c)

if __name__ == "__main__":
    a = QApplication(sys.argv)
    QObject.connect(a,SIGNAL("lastWindowClosed()"),a,SLOT("quit()"))
    w = EricdocConfigForm()
    a.setMainWidget(w)
    w.show()
    a.exec_loop()
