URI: 
       tseed dialog with clipboard and qr buttons - electrum - Electrum Bitcoin wallet
  HTML git clone https://git.parazyd.org/electrum
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
       ---
   DIR commit ff0d4512896d35d2061916201ff9f1805da85899
   DIR parent 3d22b58ecd24a909e1ef3e49ed4aaa96edd1d660
  HTML Author: ThomasV <thomasv@gitorious>
       Date:   Sat,  5 May 2012 16:42:42 +0200
       
       seed dialog with clipboard and qr buttons
       
       Diffstat:
         M gui_qt.py                           |      46 +++++++++++++++++++++++++++----
       
       1 file changed, 40 insertions(+), 6 deletions(-)
       ---
   DIR diff --git a/gui_qt.py b/gui_qt.py
       t@@ -519,7 +519,7 @@ class ElectrumWindow(QMainWindow):
                addr = unicode( i.text(0) )
        
                hbox.addWidget(EnterButton("QR",lambda: self.show_address_qrcode(addr)))
       -        hbox.addWidget( EnterButton("Copy to Clipboard", lambda: self.app.clipboard().setText(addr)))
       +        hbox.addWidget(EnterButton("Copy to Clipboard", lambda: self.app.clipboard().setText(addr)))
                if is_recv:
                    def toggle_freeze(addr):
                        if addr in self.wallet.frozen_addresses:
       t@@ -702,19 +702,53 @@ class ElectrumWindow(QMainWindow):
                    return
        
                msg = "Your wallet generation seed is:\n\n" + seed \
       -              + "\n\nPlease keep it in a safe place; if you lose it, you will not be able to restore your wallet.\n\n" \
       -              + "Equivalently, your wallet seed can be stored and recovered with the following mnemonic code:\n\n\"" \
       +              + "\n\nPlease keep it in a safe place; if you lose it,\n you will not be able to restore your wallet.\n\n" \
       +              + "Equivalently, your wallet seed can be stored and\n recovered with the following mnemonic code:\n\n\"" \
                      + ' '.join(mnemonic.mn_encode(seed)) + "\""
        
       -        QMessageBox.information(parent, 'Seed', msg, 'OK')
       -        if parent: ElectrumWindow.show_seed_qrcode(seed)
       +        d = QDialog(None)
       +        d.setModal(1)
       +        d.setWindowTitle("Seed")
       +        d.setMinimumSize(400, 300)
       +
       +        vbox = QVBoxLayout()
       +
       +        hbox = QHBoxLayout()
       +        l = QLabel()
       +        l.setPixmap(QPixmap(":icons/seed.png").scaledToWidth(48))
       +        hbox.addWidget(l)
       +        hbox.addWidget(QLabel(msg))
       +        vbox.addLayout(hbox)
       +
       +        hbox = QHBoxLayout()
       +        hbox.addStretch(1)
       +
       +
       +        if parent:
       +            app = parent.app
       +        else:
       +            app = QApplication
       +
       +        b = QPushButton("Copy to Clipboard")
       +        b.clicked.connect(lambda: app.clipboard().setText(' '.join(mnemonic.mn_encode(seed))))
       +        hbox.addWidget(b)
       +        b = QPushButton("View as QR Code")
       +        b.clicked.connect(lambda: ElectrumWindow.show_seed_qrcode(seed))
       +        hbox.addWidget(b)
       +
       +        b = QPushButton("OK")
       +        b.clicked.connect(d.accept)
       +        hbox.addWidget(b)
       +        vbox.addLayout(hbox)
       +        d.setLayout(vbox)
       +        d.exec_()
        
            @staticmethod
            def show_seed_qrcode(seed):
                if not seed: return
                d = QDialog(None)
                d.setModal(1)
       -        d.setWindowTitle(seed)
       +        d.setWindowTitle("Seed")
                d.setMinimumSize(270, 300)
                vbox = QVBoxLayout()
                vbox.addWidget(QRCodeWidget(seed))