From ac044fc434074aa3664cb0029267f00e900cd300 Mon Sep 17 00:00:00 2001 From: "Veronica K. B. Olsen" Date: Sat, 8 Jun 2019 15:15:06 +0200 Subject: [PATCH] Trying an editable table --- nw/gui/projecteditor.py | 4 +++- sample/sampleNovel/meta/sessionInfo.log | 18 ++++++++++++++++++ sample/sampleNovel/nwProject.nwx | 6 +++--- 3 files changed, 24 insertions(+), 4 deletions(-) diff --git a/nw/gui/projecteditor.py b/nw/gui/projecteditor.py index 515f709b..7837240e 100644 --- a/nw/gui/projecteditor.py +++ b/nw/gui/projecteditor.py @@ -314,7 +314,9 @@ class GuiProjectEditReplace(QWidget): self.mainModel = QStandardItemModel() self.mainTable.setModel(self.mainModel) self.mainTable.horizontalHeader().setSectionResizeMode(QHeaderView.Stretch) - self.mainTable.setEditTriggers(QAbstractItemView.DoubleClicked) + self.mainTable.setEditTriggers( + QAbstractItemView.DoubleClicked | QAbstractItemView.SelectedClicked | QAbstractItemView.AnyKeyPressed + ) self.mainModel.setHorizontalHeaderLabels(["Keyword","Value"]) self.mainModel.setRowCount(3) diff --git a/sample/sampleNovel/meta/sessionInfo.log b/sample/sampleNovel/meta/sessionInfo.log index ecc8f9ce..87aa2b2d 100644 --- a/sample/sampleNovel/meta/sessionInfo.log +++ b/sample/sampleNovel/meta/sessionInfo.log @@ -153,3 +153,21 @@ Start: 2019-05-31 19:58:24 End: 2019-05-31 19:59:04 Words: 0 Start: 2019-05-31 20:11:22 End: 2019-05-31 20:11:56 Words: 0 Start: 2019-05-31 20:23:06 End: 2019-05-31 20:23:18 Words: 0 Start: 2019-05-31 20:23:56 End: 2019-05-31 20:27:02 Words: 7 +Start: 2019-06-03 21:19:48 End: 2019-06-03 21:20:32 Words: 0 +Start: 2019-06-04 20:40:13 End: 2019-06-04 21:06:44 Words: 0 +Start: 2019-06-04 21:24:03 End: 2019-06-04 21:24:38 Words: 0 +Start: 2019-06-04 21:24:42 End: 2019-06-04 21:25:04 Words: 0 +Start: 2019-06-04 21:25:09 End: 2019-06-04 21:25:18 Words: 0 +Start: 2019-06-04 21:25:31 End: 2019-06-04 21:25:36 Words: 0 +Start: 2019-06-04 21:25:44 End: 2019-06-04 21:26:07 Words: 0 +Start: 2019-06-04 21:55:47 End: 2019-06-04 21:59:57 Words: 0 +Start: 2019-06-04 22:00:21 End: 2019-06-04 22:00:29 Words: 0 +Start: 2019-06-04 22:00:54 End: 2019-06-04 22:01:03 Words: 0 +Start: 2019-06-04 22:01:21 End: 2019-06-04 22:01:36 Words: 0 +Start: 2019-06-04 22:02:48 End: 2019-06-04 22:02:55 Words: 0 +Start: 2019-06-04 22:08:26 End: 2019-06-04 22:08:33 Words: 0 +Start: 2019-06-04 23:00:20 End: 2019-06-04 23:00:35 Words: 0 +Start: 2019-06-04 23:01:25 End: 2019-06-04 23:02:29 Words: 0 +Start: 2019-06-04 23:09:01 End: 2019-06-04 23:10:26 Words: 0 +Start: 2019-06-04 23:12:15 End: 2019-06-04 23:16:42 Words: 0 +Start: 2019-06-04 23:18:50 End: 2019-06-04 23:19:16 Words: 0 diff --git a/sample/sampleNovel/nwProject.nwx b/sample/sampleNovel/nwProject.nwx index 7cad49d7..f10a9cc7 100644 --- a/sample/sampleNovel/nwProject.nwx +++ b/sample/sampleNovel/nwProject.nwx @@ -1,5 +1,5 @@ - + Sample Project Sample Project @@ -8,7 +8,7 @@ True - bc0cbd2a407f3 + 636b6aa9b697b None 565 @@ -76,7 +76,7 @@ 656 121 5 - 77 + 442 New File