Commit graph

722 commits

Author SHA1 Message Date
Curtis Gedak b473ead98e Fix word recognition for spell checker, ignore active partial words
See PR #651

This commit restores the functionality that prevents spell checking a
word that is being actively typed at the end of a paragraph.

The goals for the spell check word match regexp are:

A. Words should include those with an apostrophe
   *E.g., can't*
B. Words should exclude underscore
   *E.g., hello_world is two words*
C. Words in other languages should be recognized
   *E.g., French word familiarisé*
D. Spell check should include word at absolute end of line with no
   trailing space or punctuation
   *E.g., tezt*
E. Spell check should ignore partial words in progress (user typing)
   *E.g., paragr while midway through typing paragraph*

This commit addresses all five of the above goals.

HISTORY:
- See issue #166 and commit 6ec0c19 in the 0.5.0 release.
- See issue #283 and commit 63b471e in the 0.7.0 release.

Also fix minor incorrect utf-8 encoding at top of source file.
2019-09-22 10:28:49 -06:00
Curtis Gedak 10df2baf8d Fix typo missed in two previous commits
See PR #645 and PR #648.

Change second instance in string of "save" to "saved".
2019-09-19 10:38:16 -06:00
luz.paz d20e7a8122 Fix typo missed in previous commit
https://github.com/olivierkes/manuskript/pull/489#issuecomment-533195819
2019-09-19 10:13:15 -06:00
luz.paz 2fd45dc42c Fix misc. typos
Found via `codespell -q 3 -S *.ts,./libs,./sample-projects -L searchin`
2019-09-19 09:58:24 -06:00
Curtis Gedak 0943d81317 Move Qt 5.11 / 5.12 version warning to Import invocation
See issue #611 and pull request #642.

The warning previously added in PR #612 for Manuskript users with Qt
5.11 / 5.12 has shown itself, in my opinion, to be overly annoying.
This is because the warning *always* displays on systems with the
affected Qt versions even though the crash is verified to happen with
the import feature only.

Additionally the process to upgrade to a newer version of PyQt / Qt is
not trivial for users who rely on pre-built packages and do not run
from source code.

Because the crash has been verified with the Import feature only, limit
the scope of the warning to the Import feature.
2019-09-17 10:41:33 -06:00
luz.paz 1368a9b79b Fix source typo
Split off from #489
2019-09-17 10:26:46 -06:00
Jan Wester 5dcd93ced3 Improved detection of UI language
The user can configure a language for Manuskript in the dialog, but
before that setting is ever written to disk, there is the default
behaviour that tries to auto-detect the best language to show based on
the configuration of the device it is running on.

While doing my due diligence on issue #619, I realized we were relying
on the system locale, which is not necessarily equivalent to the
language the user is working with. Worse still: a user can have multiple
preferred languages for their user interface, and our old approach might
actually offer them the 'wrong' language. This patch fixes this.

It also refactors and comments things a little bit where necessary.
2019-09-15 09:21:31 -06:00
Jan Wester 0aa83180de Reworked translation loading to avoid ambiguity
Issue #619 revealed an unintentional overlap between the auto-detection
of the locale and the implicit builtin English language, which resulted
in users being unable to select the builtin English language when their
device was configured with a locale that we happen to have a translation
for. The code has been rewritten to more clearly separate auto-detection
and the final fallback that is the builtin English translations.
2019-09-15 09:21:31 -06:00
Curtis Gedak a2fc4c5ecd Set default window tab to Word frequency for Frequency Analyzer tool
This code change sets:
- Fequency Analyzer tool default first tab of "Word frequency"
  (was Phrase frequency)

Steps to set default window tab:

1. Start Qt Designer
2. Open .ui file
3. Ensure that each selected window tab is the one desired as default
4. Save .ui file
5. Exit Qt Designer
6. Generate .py file with:  make ui

See PR #623
2019-09-13 10:00:29 -06:00
Curtis Gedak 8f4ddefb48 Fix tab key order, and default window tab for character pane and plot pane
This code change sets:
- Character pane default first tab of "Basic info" (was Notes)
- Character pane Basic info "Name" as the default first field (was Motivation)
- Plots pane default first tab of "Basic info" (was Resolution steps)

Steps to edit tab order and default window tab:

1. Start Qt Designer
2. Open .ui file
3. Choose menu **Edit -> Edit Tab Order**
4. Ctrl-click on item just before the first incorrect tab order item
5. Click other items in order until remaining order is correct
6. Ensure that each selected window tab is the one desired as default
7. Save .ui file
8. Exit Qt Designer
9. Generate .py file with:  make ui

See https://doc.qt.io/qt-5/designer-tab-order.html

This code change implements a portion of issue #244
2019-09-13 10:00:29 -06:00
Jan Wester d626d3ba75 Fixed & robustified image tooltips (issue #593)
Last time I touched this code, I went in looking for a specific problem,
and came out with a fix specific to that issue. That fix was not wrong,
yet it hardly covered all the problems present in the code once one took
into account issues like:

- local vs remote resources,
- relative vs absolute paths,
- different operating systems behaving differently, and
- Qt being uniquely buggy on different platforms.

The major part of it was fixed by using QUrl.fromUserInput(), which does
the exact kind of auto-detection for the nature of the resource that we
were in need of.

The rest of the issues were fixed by creating a number of test cases and
fixing problems as they popped up. Testing was done in Windows & Ubunty
against the above-mentioned test cases, which can be found in PR #629.

Regarding ImageTooltip.supportedSchemes

When QUrl.fromUserInput() misidentifies the scheme on Linux, it causes
all resemblance between the original request and the reply.request() in
the finished() signal to be lost, which results in this item getting
stuck in the ImageTooltip processing pipeline.

Limiting the supported schemes to the ones most commonly encountered
('file', 'http', 'https' and the schema-less local paths) is the only
reliable method I have found to work around this particular bug in Qt.
2019-09-10 11:30:35 -06:00
Jan Wester 860ada2c1b Basic dark theme support (Windows 10)
Windows 10 has supported a 'dark theme' option for a while, and the fact
Manuskript is like looking into a bastion of bright white while using it
is bothersome to say the least.

Since this is a setting defined as the OS level, I believe this should
be something Manuskript automatically adjusts itself to match, thus the
lack of a configurable setting on the Manuskript end.
2019-09-10 10:15:54 -06:00
Jan Wester 5da31230c7 Fixed crash for pre-Qt5.6
Qt has garbage documentation. I dug into Qt 5.0 source code to make sure
the crashing call can be safely left out for older versions, and that is
indeed the case. setSupportedSchemes() appears to be introduced together
with the future to select non-local files in the dialog, but we only
cared about local files to begin with.
2019-09-07 15:59:45 -06:00
Jan Wester f6fa3e8375 Do not try to export after dismissing the dialog
I happened to notice the UI briefly locking up when testing my previous
changes on some of the Pandoc exporters. While the bigger mess I found
along the way is more than a little fix can handle, this stopgap measure
will at least stop us from running pandoc when it isn't needed.
2019-09-07 15:59:45 -06:00
Jan Wester 9317dc97d8 Do not reinvent QFileDialog's default suffix
According to issue #608 we were silently overwriting files when there
was a suffix being generated for a chosen export filename when one was
missing to begin with. Unfortunately, this helpful feature avoids all
the conveniences offered by QFileDialog in regards to alerting the user
to overwriting an existing file. Worse still, this feature already
exists in QFileDialog and the native APIs it can rely on.

This patch reimplements QFileDialog.getSaveFileName to allow the use of
the default suffix feature as functions.getSaveFileNameWithSuffix and
removes most of the magic involved with the old solution.
2019-09-07 15:59:45 -06:00
Jan Wester bcf749d165 Use native look for the import FileDialog
It is the only FileDialog in the entire codebase that does not conform
to the rest of the OS like its brethren, and it stuck out like a sore
thumb because of it.
2019-09-04 14:18:02 -06:00
Jan Wester c2dce6e0c6 Warn user about buggy libraries
Some bugs are out of our reach to fix, but can still impact the user
considerably. Because losing progress always hurts, we want to make
the user aware of the risks before any tears are shed. (PR #612)
2019-09-04 14:18:02 -06:00
Jan Wester fe0405ca8f Reinstate importer-specific settings in UI
Once upon a time very long ago, someone commented out one line too many.

And that broke all Pandoc-based imports. Oops. See issue #611.
2019-09-04 14:18:02 -06:00
Curtis Gedak 65fb184f60 Rename setting "Save on quit" to "Save on project close"
See PR #615

This rename is being done to clarify that when a user enables "Save on
project close" then the project will be saved whenever the user
chooses to close the project or to quit Manuskript.

Note that the actual name of the setting saveOnQuit should also be
changed but instead has been marked as a future TODO because it
involves a change in the project file format.
2019-08-22 15:18:18 -06:00
Curtis Gedak f4c8108b28 Do not prompt "Save project?" when _Save on quit_ setting enabled
See PR #615

The Travis CI tests began failing after merging Pull Request #583.

Log snippet:

----------------------------------------------------------------------
...
Ref not implemented
PASSED
manuskript/tests/ui/test_welcome.py::test_autoLoad QXcbConnection: XCB error: 8 (BadMatch), sequence: 613, resource id: 2097162, major code: 42 (SetInputFocus), minor code: 0
QXcbConnection: XCB error: 8 (BadMatch), sequence: 619, resource id: 2097168, major code: 42 (SetInputFocus), minor code: 0
QXcbConnection: XCB error: 8 (BadMatch), sequence: 625, resource id: 2097171, major code: 42 (SetInputFocus), minor code: 0
----------------------------------------------------------------------

When running "pytest -vs" locally, which is a command used in our
.travis.yml file, a dialog to "Save project?" is displayed.  Because
the test scripts use the "saveOnQuit" default setting of *enabled*,
the "Save project?" dialog should not be displayed.

In other words when a call is made to close the project, a "Save
project?" dialog is incorrectly displayed because the dirtyProject
flag is set, but so too is saveOnQuit set to True.  What should happen
is an automatic save with no prompt.  This PR fixes this logic so that
the Travis CI test suite completes successfully.
2019-08-22 15:18:18 -06:00
Jan Wester 34f84126df Fixed race when closing an auto-saving project.
Turning off the timer for saveTimerNoChanges just like the code
already did in closeProject() for saveTimer fixes this bug. Easy.

But how to prevent this kind of race condition in the future?

Several related routines have been adjusted to fail gracefully or report
a bug to the console when something goes wrong, depending on what is
most suitable for that bit of logic.
2019-08-12 10:35:07 -06:00
Jan Wester 97cf0e1373 Track dirty state and have the UI respect it
Intending to learn more about the way Manuskript goes about saving the
project in order to figure out how to tackle some recent saving-related
issues, I stumbled into learning that Manuskript likes to save data a
whole lot. Too much, in fact. When I close the project with unsaved
changes, I expected those changes to not be saved... but they were. This
completely subverts my expectations of a program using typical
file-based operations involving opening, saving and closing files.

There are three more settings that influence when the program saves, and
I personally consider them a bit overkill or even detrimental to the
stated purpose. What if Manuskript forces a save when nothing was
changed and something goes wrong? Saving too much can in fact be
dangerous!

For now, I have left existing functionality as-is, but I would prefer to
respect the dirty flag I have introduced in this commit for at least the
'save-on-quit' and 'save every X minutes' features. (The third is
smarter and only triggers after noticing changes, so it is less
important.)

Making sure the dirty flag works as expected is the first step in making
such changes in the future.

UI-wise, this commit now offers the user the opportunity to save their
changes, discard them, or outright cancel their action entirely when
performing a destructive action on a dirty project. As of this commit, I
have identified two of such scenarios:

1) closing the project,
2) closing the window with save-on-quit turned off.

If I missed any, do let me know. But for now, maybe now I can finally
start digging into those issues that sent me down this rabbit hole...
2019-08-12 10:35:07 -06:00
Curtis Gedak 5f9ea3baa5 Fix crash when setting word Goal on new Text (scene) in Outline pane
See issue #561.

The problem appears to be a due to a combination of factors, such as:

- Python does not automatically convert an empty/blank variable to the
  integer zero (0)
- Default goal value is empty/blank for a new Text (scene)
- Asynchronous events can occur such that the change in the Outline
  pane of a new Text (scene) goal from empty/blank to a value is not
  saved to the data model prior to the update event in the Editor pane
  accessing the model value for the word count progress display.

Steps to Reproduce:

1. Start manuskript and create new project (no template).

2. Select **Outline** pane.

3. Click "Text Plus" icon to create a text (default name "New")

4. Select **Editor** pane.

5. Click on **New** to display empty text.

6. Select **Outline** pane.

7. Double-click the empty area on **New** line under title **Goal**,
  type in "300", and press **Enter**.

   Note that manuskript crashes with a segmentation fault.

Work around the crash by using the already existing manuskript
function toInt() which handles conversion of empty/blank values to
integer value zero (0).
2019-07-31 10:46:06 -06:00
Curtis Gedak dc51f6d84e Add new language translations to the Settings window 2019-07-14 10:11:52 -06:00
Allan Nordhøy 761be5784a Spelling: Manuscript, could not, process, … No content (#588)
* Spelling: Plaintext, Manuscript, could not, process, … No content

* Reverted to "plain text"
2019-06-06 11:55:24 -06:00
NocturnalFred 995eda101f fix issue #468 'unit' is reset 2019-06-05 10:34:11 -06:00
Curtis Gedak 1711f8decf Fix pandoc export crashes is project title is empty
Fixes #535
2019-05-31 10:19:04 -06:00
Youness Alaoui a8ec6512c9 Fix crash if invalid character is inserted into the text.
If an invalid character is inserted into the text, such as a "^L" (ASCII 0x0C)
when copy-pasting from a google document that has a page break in it, a crash
will happen as the character cannot be inserted into XML. This patch removes
those invalid characters from the text so the revisions.xml can be saved.

Fixes #562
2019-05-21 09:52:18 -06:00
Youness Alaoui f1baab8b3a Fix crash if using a custom pandoc installation
Fixes #563
2019-05-20 09:39:45 -06:00
Youness Alaoui 3dfb43f6c1 Center dialog for the frequency analyzer too. 2019-05-20 09:25:17 -06:00
Youness Alaoui e4da844708 Fix dialog windows being created outside the desktop area
The About/Settings/Import/Export/ExportManager windows were all created
in odd places, usually to the left of the main window, which meant outside the
desktop area with little overlap if the main window is maximized. The logic in
centering the window on its parent was wrong. This fixes it.
2019-05-20 09:25:17 -06:00
Jan Wester 12390a9aab Fix occasional crashes when (re)moving items
Describing all the rabbitholes that I and kakaroto have gone through
while debugging this one until dawn can frankly not do enough justice to
the crazy amount of rubberducking that went on while trying to fix this.

This bug would be triggered whenever you had a document open in the
editor and then moved an ancestor object downwards (visually) in the tree.
Or when you simply deleted the ancestor. Depending on the exact method
that caused the opened item to be removed from the internal model, the
exact nature of the bug would vary, which means this commit fixes a few
different bits of code that lead to what appears to be the same bug.

In order of appearance, the bugs that ruined our sleep were:

1) The editor widget was trying to handle the removed item at too late a
stage.

2) The editor widget tried to fix its view after a move by searching for
the new item with the same ID, but in the case of moving an object down
it came across its own old item, ruining the attempt.

3) The editor widget did not properly account for the hierarchical
nature of the model.

Upon fixing these the next day, it was revealed that:

4) The outlineItem.updateWordCount(emit=False) flag is broken. This
function would call setData() in several spots which would still cause
emits to bubble through the system despite emit=False, and we simply got
lucky that it stopped enough of them until now.

This last one was caused by a small mistake in the fixes for the first
three bugs, but it has led to a couple of extra changes to make any
future bug hunts slightly less arduous and frustrating:

a) When calling item.removeChild(c), it now resets the associated parent
and model to mirror item.insertChild(c). This has also led to an extra
check in model.parent() to check for its validity.

b) The outlineItem.updateWordCount(emit=) flag has been removed entirely
and it now emits away with reckless abandon. I have been unable to
reproduce the crashes the code warned about, so I consider this a code
quality fix to prevent mysterious future issues where things sometimes
do not properly update right.

Worthy of note is that the original code clearly showed the intention to
close tabs for items that were removed. Reworking the editor to support
closing a tab is unfortunately way out of scope, so this intention was
left in and the new fix was structured to make it trivial to implement
such a change when the time comes. An existing FIXME regarding unrelated
buggy editor behaviour was left in, too.

Many thanks to Kakaroto for burning the midnight oil with me to get to
the bottom of this. (I learned a lot that night!)

Issues #479, #516 and #559 are fixed by this commit. And maybe some others,
too.
2019-05-19 09:33:19 -06:00
Jan-Niklas Meier 385396c089 trying to resolve full screen exit issues on macOS 2019-05-03 09:41:39 -06:00
Youness Alaoui d513351162 spellchecker: Add file header to spellchecker.py 2019-04-30 09:54:31 -06:00
Youness Alaoui 4f7c81bbff spellcheck: Handle use case of a dictionary becoming unavailable. 2019-04-30 09:54:31 -06:00
Youness Alaoui 5c33ce54f3 spellcheck: show 'add to dictionary' even if a word has no suggestions 2019-04-30 09:54:31 -06:00
Youness Alaoui f9b181ff67 spellchecker: Improve support for symspellpy
Add support for 6.3.8 which has delete_dictionary_entry and do not use gzipped
pickle. Also give higher priority to symspellpy vs pyspellchecker.
List symspellpy dictionaries by order of cached vs non-cached.
symspellpy 6.3.8 is now the minimum version required and add support for showing
that information to the user.
Also add support for spellcheck libraries that are installed but without dicts.
2019-04-30 09:54:31 -06:00
Youness Alaoui e1edccc7d3 spellchecker: Add SymSpellPy support
SymSpell is a great spellchecker which works a lot faster than
pyspellchecker for finding suggestions but is a bit slow at
loading dictionaries (about 15 seconds initially, 2 seconds if
using a cached version).
SymSpell also doesn't come with dictionaries, so the code is currently
using dictionaries from pyspellchecker, so if pyspellchecker isn't
installed, then the user won't see any available dictionaries.
Eventually, would need to have an interface for people to manage
dictionaries for it.
2019-04-30 09:54:31 -06:00
Youness Alaoui e1b063a953 spellchecker: improve custom dictionary support
Improves the custom dictionary support by making it more generic
and moving it to the base class. Also makes PyEnchant uses a custom
PWL (Personal Word List) file within manuskript's resources directory
and made pyspellchecker detect available languages automatically.
2019-04-30 09:54:31 -06:00
Youness Alaoui 20c5586a6c Add support for pyspellchecker as an alternative to PyEnchant
This modifies the Spellchecker abstraction to add a new dictionary support, with
support for pyspellchecker. It also changes the main UI so that multiple libraries
can be supported and dictionaries provided to the user. The custom dictionary of
pyspellchecker has to be handled manually, and the performance and words of this
library isn't on par with PyEnchant, but at least it works with 64 bits.

Fixes #505
2019-04-30 09:54:31 -06:00
Youness Alaoui d0f02cb2a7 Add a Spellchecker abstraction layer and clean up code
This is in preparation for adding support for additional spellchecking libraries
other than PyEnchant which seems to be unmaintained and does not build in
Windows 64 bit.
2019-04-30 09:54:31 -06:00
Jan Wester 0238ccec7b Fixed #549 and refactored the image tooltip also
Issue #549 was caused because the request and reply object urls are not
guaranteed to be the same. Redirects are the most common cause, but a
malformed URL apparently also qualifies. We now make sure to look at the
original request.

Because the code confused me while I was working on it, I decided to
refactor and document it in order to understand what was going on. I am
glad I did: I found another crashing bug involving the rapid-firing of
tooltip requests, and the processing dict never had its entries removed
either, leading to a (very slow) memory leak over time.

All is good in the world of image tooltips now.
2019-04-23 12:25:39 -06:00
Curtis Gedak f6293ca3d9 ========== manuskript-0.9.0 ========== 2019-04-04 10:34:25 -06:00
Curtis Gedak 362673ec21 Update copyright year 2019-04-04 10:33:08 -06:00
Curtis Gedak fbbdead43e Add new language translations to the Settings window 2019-04-04 10:08:17 -06:00
Youness Alaoui 5a9c82a03a fullscreen: Rework panel 'addDisplay' API and improve top panel Path UX
The 'displays' system of panels is now changed into simply a settings system
where settings can be associated to widgets. The new API is :
addWidgetSetting, addSetting and setSettingCallback.

The top panel was reworked to have the settings appear in the order of the
widgets, and the path/title choice was changed into a Title widget with a
"Title: Show Full Path" setting.
2019-04-02 11:42:25 -06:00
Youness Alaoui 156e2d0067 fullscreen: Add a auto-show/hide progress setting.
Realizing that the show/hide progress was being ignored if we navigate to a
scene without a goal set. Also, if we go fullscreen on a scene without a goal
then navigate to a scene with one, the progress wouldn't get shown. Adding the
"Auto Show/Hide" setting fixes the issue with all use cases.
2019-04-02 11:42:25 -06:00
Youness Alaoui 8900a0ed3f fullscreen: Change navigation/new-document layout
Left-align the navigation and new-document buttons in the top panel to
prevent them from moving around when changing scenes.
2019-04-02 11:42:25 -06:00
Youness Alaoui a27a1f399a Adding navigation support to fullscreen editor
This makes the fullscreen editor much more powerful in terms of navigating
through chapters and scenes. This should make issue #234 users happy and
fix #444.

Top panel now has left/right arrows to navigate through the scenes. It will
automatically find the next/previous text item and display it, navigating through
the outline tree.

There's also a "New document" icon which will create a new text entry immediately
after the current one and switch to it.

Navigation can also be done using Alt+Page-Up, Alt+Page-Down or Alt+Left and Alt+right
shortcuts (Fixing #444).

There's now also the option between Title or Path for the top panel, if Path is chosen
then the full path of the scene is displayed and clicking on the scene or parent items
opens a menu to quickly switch to the selected chapter/scene. Selecting a folder will
automatically display the first text entry available in that folder.
2019-04-02 11:42:25 -06:00
Youness Alaoui 62b225e22c Fullscreen: Add scene title to top panel 2019-04-02 11:42:25 -06:00
Youness Alaoui 5d0fdb7a80 fullscreen: Add option to remove spellcheck button from top panel 2019-04-02 11:42:25 -06:00
Youness Alaoui 9312427e13 Add clock widget to the bottom panel and add setting for showing seconds
The bottom panel now has a clock widget, and the myPanel has a addSetting method
in order to add non-widget settings to the popup menu.
2019-04-02 11:42:25 -06:00
Youness Alaoui 58ab998ad9 Add ability to save fullscreen panel settings
This includes the auto-hide of each panel as well as the shown/hidden status
of each of the displays. Now that it's consistent, it makes it so much more useful.
2019-04-02 11:42:25 -06:00
Youness Alaoui 932550be89 fullscreen: Add 'displays' to the bottom panel that can be shown/hidden.
This is an experimental idea. We can add to a myPanel a list of widgets to show/hide
if the user wants to, via the context menu. This can be very useful for a user who
wants to disable auto-hide for the bottom panel but remove the theme selector which
can be useless to have open permanently.

This is the first step in fixing #234. Would need the auto-hide and the displays
configurations to be saved in settings though before it can become usable.
2019-04-02 11:42:25 -06:00
Youness Alaoui 4a947a95ac Add support for IPython Jupyter QT Console as a debugging aid
If manuskript is launched with its last argument set to "--console" an
interactive console opens up to help debug the application.
The IPython, qtconsole and matplotlib libraries must be installed for it
to work and they won't get imported unless the argument is passed to the app.
2019-03-29 10:37:53 -06:00
Youness Alaoui 7c8458b0da Fix color scheme of fullscreen editor
Color scheme was inverted if foreground was transparent, bug and fix provided
by @tildagail [1] and the text on the left side panel was ignoring text color
settings, making it unreadable in dark themes, as reported by @worstje in #527

[1] https://github.com/olivierkes/manuskript/issues/527#issuecomment-469578130
2019-03-29 10:22:55 -06:00
Jan Wester 33ac127173 Directory entries in ZIP break loading code
While tackling issue #529, I stumbled across the odd behaviour that
re-compressing the archive with 7-Zip broke what should be a valid
Manuskript project.

After investigation it turned out that the code that loads the texts
sensibly expects there to only be files tracked in the files dictionary.

It is completely valid for a zip file to contain entries describing the
contained directories. The logical fix is to simply avoid adding these
directory entries to our files dictionary in the first place.
2019-03-12 14:44:51 -06:00
Youness Alaoui 143500b296 Add ability to add new background images through UI.
The Cork background and fullscreen theme backgrounds images can now be added
by using the "+" icon from the combobox. Once a file is added, the combobox
is repopulated and the new image is selected.

Note on line 871, in updateThemeBackground, there was a bug where it was using
self.cmbCorkImage instead of self.cmbThemeBackgroundImage

Fixes #399
2019-03-07 10:43:35 -07:00
Youness Alaoui a6942b7923 Fix crash when right-clicking twice on fullscreen panel
If you right click once on the fullscreen panel and the context menu pop up
then you right click again somewhere else on the panel *while the previous
context menu is still visible* then it will cause a crash with :
"Windows fatal exception: access violation"
It seems to be caused by a crash in the QT event loop, trying to delete the
existing QMenu within an event handler.
2019-02-28 10:58:23 -07:00
Youness Alaoui 3f217257c4 Fix background of popup menus that was transparent (black)
In the properties view, the context menu on the title line would be black
making its content unreadable. Same in the filter line of the "Set Custom icon"
window on the outline's context menu.
2019-02-27 10:49:05 -07:00
Curtis Gedak 4fdacc24f7 Ensure text file open methods use utf-8 encoding
Several crashes were encountered opening files on operating systems
that do not default to UTF-8 encoding, such as Windows.  In each case
the project file appears to have become corrupted.  Because the only
reports to date have been on Windows, attempt to fix by specifying
utf-8 encoding for all text file open methods.

See issues #331, #470, and #502.
2019-02-27 09:30:16 -07:00
Youness Alaoui 7928ea2796 Fix corkView background image on Windows
Windows path to the image has '\' path separator instead of '/' which makes
the stylesheet fail. Background images don't appear and console gets spammed with :
Could not parse stylesheet of object corkView(0x27248eb6900, name = "corkView")
2019-02-26 13:25:30 -07:00
Youness Alaoui c3c9eef415 Do not default spellcheck to True for new editor views
default spellcheck to the settings value instead. Otherwise any new editor tab
will have spellcheck enabled regardless of setting.

Fixes #474
2019-02-25 12:58:00 -07:00
Youness Alaoui 84d0979ffb Set editor theme stylesheet to QTextEdit only.
This prevents any child widget from inheriting the same stylesheet,
more specifically, the context menu of the full screen editor will now
appear normal instead of being black text on black background, which made
it unreadable.

Fixes #440
2019-02-25 11:15:16 -07:00
Youness Alaoui 4a9937f041 Do not use a lambda function in the fullScreenEditor's myScrollBar timer signal
The lambda function will keep a reference to the scrollbar python object preventing it
from getting destroyed when the QScrollbar is destroyed. This causes the underlying
QT widget to be freed while the python object still exists, therefore the timer itself
doesn't get stopped/cleaned, so the timer will get called and cause a crash with :
"RuntimeError: Wrapped C/C++ object of type myScrollbar has been deleted"

To reproduce, press F11 repeatedly while scrolling.
2019-02-25 10:22:48 -07:00
Youness Alaoui c7605b5819 Don't crash if a typo is made in the exporter's regular expression.
When a regexp error is thrown, cancel the export and show an info dialog
with the error message to the user. Fixes #488
2019-02-15 12:49:22 -07:00
Curtis Gedak baeb5f4653 2nd try to fix macOS X blank screen when leaving fullscreen editor mode
See issue #24.

The first attempt to fix this problem was with commit:

    Try to fix macOS X blank screen when leaving editor fullscreen mode
    1ae0a77464
2019-02-12 11:23:29 -07:00
Youness Alaoui 9b774d327f Fix crash when right clicking a word in editor and enchant is not installed. 2019-02-11 12:35:23 -07:00
Youness Alaoui d7203ddacf Fix crash when previewing pandoc HTML with QTextEdit as web rendering engine. 2019-02-11 10:27:35 -07:00
Youness Alaoui caed3e9224 Fix crash when 7 pound signs are written alone on a line.
The code would look for trailing pound signs and would
count all the way to the beginning and beyond, resulting
in an out of bounds exception.
2019-02-10 09:54:50 -07:00
Curtis Gedak 1ae0a77464 Try to fix macOS X blank screen when leaving editor fullscreen mode
Ensure showNormal() is called after leaving showFullScreen().

See issue #24.

References:

https://stackoverflow.com/questions/31666744/pyqt5-can-not-close-a-topmost-fullscreen-qdialog-on-mac-osx

https://doc.qt.io/qt-5/qwidget.html#showFullScreen
  - To return from full-screen mode, call showNormal().

https://pythonprogramminglanguage.com/destructor/
2019-02-09 10:27:44 -07:00
Curtis Gedak f75bc69dd7 Fix spelling mistake "chose" should be "choose"
Mentioned in issue #470
2019-02-07 12:34:57 -07:00
Curtis Gedak 1cc7146aad Avoid crash on import
See issue #470
2019-02-07 12:34:57 -07:00
nephlm 592a4fddb7 #459 - remove debug/dead code 2019-01-22 00:41:32 -05:00
nephlm 4f2d57e86f Issue 459 - session progress/goal window 2019-01-22 00:37:22 -05:00
Allan Nordhøy f731e19e00 Spelling: Manuscript, may have to be restarted (#454)
* Spelling: Manuscript, may have to be restarted
2019-01-10 10:26:14 -07:00
LingSamuel 4ded8d29e0 fix #411: translator won't work in some window, such as settings 2018-12-09 11:35:34 -07:00
LingSamuel 3d6080f3c0 fix #428: zh translation suffix doesn't match system locale; new behavior: load translation from settings first 2018-12-09 11:19:26 -07:00
LingSamuel cbf35fa373 Open/Save As/Create last accessed directory 2018-12-07 12:01:33 -07:00
LingSamuel 7bbc112d25 Add last accessed directory 2018-12-07 12:01:33 -07:00
Curtis Gedak 0cbf337f09 ========== manuskript-0.8.0 ========== 2018-12-05 11:39:28 -07:00
Curtis Gedak 92b0f016ba Add new language translations to the Settings window 2018-12-05 10:41:33 -07:00
Curtis Gedak 528ea130ee Remove unimplemented snowflake view mode menu entry
The menu option "View -> Mode -> Snowflake" has not been implemented.
This greyed out / disabled option has caused some confusion for users.
Remove the snowflake menu option to avoid confusion.

Closes issue #419
See also earlier issue #45
2018-11-30 09:42:42 -07:00
Curtis Gedak 5ea37bd192 Remove plot resolution step key bindings Ctrl+Enter and Ctrl+Backspace
Many applications, including Manuskript in the Editor pane, use the
keyboard shortcut 'Ctrl+Backspace' to delete the previous word.
However in the Plot pane Manuskript uses 'Ctrl+Backspace' to delete a
plot resolution step.

Fix this inconsistent behaviour by removing the keyboard shortcuts for
'Ctrl+Enter' and 'Ctrl+Backspace' from the Plot pane.

Closes issue #375
2018-11-26 11:05:46 -07:00
Curtis Gedak 98a629454e Add support for pandoc v2 command line options
Now both pandoc v1 and v2 are supported.

Closes issue #304
2018-11-20 10:21:48 -07:00
Curtis Gedak 60b58d9658 Fix Python 3.7 DeprecationWarning use local.format_string() messages
Fix by replacing locale.format() with locale.format_string().
2018-11-16 12:52:56 -07:00
Curtis Gedak 7f592bae41 Fix Python 3.6 DeprecationWarning invalid escape sequence messages
Fix by ensuring that regular expressions are constructed using either
raw string literals [1] or double backslashes [2].

[1] https://stackoverflow.com/questions/44325948/pandas-invalid-escape-sequence-after-update
[2] https://github.com/joblib/joblib/pull/526

Note that python only shows the deprecation warnings on initial run [3].

[3] https://bugs.python.org/issue30091

To work around this issue, remove the cached bytecode with:

    find . -name "__pycache__" -exec rm -rf {} \;

Then to prevent compiling to bytecode add the "-B" option to python:

    python3 -B -m pytest -vs
2018-11-16 12:52:56 -07:00
Curtis Gedak af53102e77 Fix pytest warning about duplicate name when running tests
When running pytest on kubuntu 16.04 the following warning was displayed:

    $ python3 -m pytest -v
    ...
    ./manuskript/load_save/version_1.py:319: \
    UserWarning: Duplicate name: 'outline/0-Folder/0-Text-3.md'
      zf.writestr(filename, content, compress_type=compression)

The error was tracked down using the following pytest invocation:

    $ python3 -m pytest -v -W error::UserWarning

This invocation showed 4 occurrences similar to the following warning:

    self = <zipfile.ZipFile filename='/tmp/tmpgs_sjpzr.msk' mode='w'>
    zinfo = <[AttributeError("compress_size") raised in repr()] \
    ZipInfo object at 0x7f3cc0124588>

        def _writecheck(self, zinfo):
            """Check for errors before writing a file to the archive."""
            if zinfo.filename in self.NameToInfo:
                import warnings
    >           warnings.warn('Duplicate name: %r' % zinfo.filename, \
                stacklevel=3)
    E           UserWarning: Duplicate name: 'outline/0-Folder/0-Text-3.md'

These warnings arose in the following 4 tests:

  - test_references
  - test_autoLoad
  - test_loadExportWiget
  - test_loadImportWiget

The cause of the issue is that in manuskript/tests/conftest.py, the
mainWindow::closeProject() method is called to close the project, but
the project was never loaded.  This meant the zip file setting
defaulted to True, when in fact the Acts sample project is not stored
in a single zip project file.

Fix by removing the call to MW.closeProject() before the project is
loaded.
2018-11-16 12:52:09 -07:00
Curtis Gedak b0774b4149 Fix segmentation fault on import
Manuskript started to segmentation fault on import starting with Qt 5.11.

I found the following link and the Qt bug links within to be useful in
my trouble-shooting efforts.

[Qt 5.11] Various Applications Segfault in 'libfm-qt'
https://github.com/lxqt/libfm-qt/issues/164

Closes issue #402
2018-11-11 13:31:06 -07:00
Curtis Gedak 026861ee87 Fix plot importance changes if delete earlier plot and click other plots
The root cause was a mismatch between plot IDs and plot model rows.

This issue would appear when a plot was deleted such that the plot IDs
did not match the plot model row numbers and different plots had
different importance levels.  The problem would not occur if the most
recently added plot was deleted.

The plot ID / plot model row mismatch was introduced with the
following commit:

    Fixes: add plot then choose new plot does not set \
    importance slider
    3569f78928

Closes issue #404
2018-11-05 09:29:53 -07:00
Curtis Gedak 729489a77e Improve pandoc compile/export return code handling
See issue #186
2018-10-31 10:31:53 -06:00
RiderExMachina 41e9467267 Fix crash in Outline mode with multi-item select #355
Closes issue #355 and pull request #385
2018-10-14 11:10:46 -06:00
Curtis Gedak 21423734e9 Revert "Minor grammar fixes"
This reverts commit 2fdf8c64bf.

The problem introduced by the commit is that the Editor pane would
incorrectly label book elements with the plural form of a word.  For
example "Books 4", "Sections 2", "Chapters 1", or "Scenes 3".  Hence
the need to undo the commit.

Closes issue #383.
2018-09-20 14:57:44 -06:00
RiderExMachina 5f8168fb37 Moved incorrectly placed parameter to correct place. Closes #377. 2018-09-17 23:32:10 -07:00
RiderExMachina 2fdf8c64bf Minor grammar fixes
Fix grammar regarding multiple of an object.
2018-09-11 10:32:51 -06:00
Lech Baczynski 3fdef2b800 Fix for compile/export crash (error when saving in cp1250) #331
See issue #331 and pull request #340
2018-08-21 10:55:53 -06:00
Curtis Gedak 97e4679d83 ========== manuskript-0.7.0 ========== 2018-08-15 09:25:21 -06:00
Curtis Gedak 378f03c0b6 Clear Cheatsheet results when filter text empty 2018-08-14 09:04:00 -06:00
Curtis Gedak 713528a239 Fix crash if Cheatsheet filter term not found and Enter key pressed #354
See issue #354.
2018-08-14 09:04:00 -06:00
Curtis Gedak 0d84202da6 Add new language translations to the Settings window 2018-08-06 11:27:29 -06:00
Lech Baczynski e15cb80847 - formatting characters count according to locale, as in words count 2018-04-10 07:11:32 +02:00
Lech Baczynski c6da77baf9 - adding characters count. Implementing #334 2018-04-09 11:13:01 +02:00
Windspar 67db180c25 Fixes #217 - segfault when pasting text with focus mode enabled 2018-03-08 11:19:25 -07:00
JackXVII d3afa11ceb Remove _updateIndexFromID from textEditView
It is not used anymore.
2018-03-03 12:53:52 -07:00
JackXVII 3a21ddd137 Use QPersistentModelIndex in textEditView
It is much simpler than catching rowsAboutToBeDeleted signal from model. Also
it fixes #306.
2018-03-03 12:53:52 -07:00
Curtis Gedak 63b471e10d Make word match for spell check exclude underscore from words
See issue #283.

Adds (?!_) to perform negative lookahead to exclude "_" from pattern match.

https://stackoverflow.com/questions/14858346/regular-expressions-how-to-express-w-without-underscore
2018-02-20 10:51:57 -07:00
Windspar 4638ba878f stop crash when click btnGoUp and current editor is None 2018-02-18 14:06:33 -05:00
Curtis Gedak 43c077552a Avoid crash on spellcheck by ensuring enchant dictionary exists
See issue #273.
2018-02-12 10:59:14 -07:00
Allan Nordhøy 62a8a136c0 Spelling: LaTeX, Pandoc, XeLaTeX, Unicode, HTML. https link
See pull request #310.
2018-02-12 10:52:35 -07:00
Sebastian Rasmussen dde836e0f4 Fix typos that are visible to end-users. 2018-01-29 10:30:41 -07:00
Sebastian Rasmussen dfe88a9681 Fix typos in code comments, invisible to end-users. 2018-01-29 10:30:41 -07:00
Olivier Keshavjee 4a9dc00381 Fixes #307: Overlay status bar prevents access to add/delete world item icons when displaying a message 2018-01-22 18:19:22 +01:00
Olivier 30a49a44d4
Merge pull request #302 from gedakc/issue-281-hidden-file-crash-open-project
Skip loading directory and file names that begin with a period
2018-01-18 10:18:58 +01:00
JackXVII 8a9044b4ae Fix World items positional insertion 2018-01-15 22:02:43 +03:00
JackXVII 43df0b3d8a Fix World sub-items disappearing 2018-01-15 18:29:21 +03:00
Curtis Gedak 60cc6c59aa Skip loading directory and file names that begin with a period
See issue #281.

When loading a project that has the setting **Save to one single
file** disabled, Manuskript tries to read all directories and files
under the project directory.

Manuskript expects all files to contain valid unicode characters.

However if a file containing non-unicode characters is read then
Manuskript will crash.

The error message displayed on the console is similar to the
following:

----- begin snippet -----
Traceback (most recent call last):
  File "/home/gedakc/workspace/manuskript.olivierkes/bin/../manuskript/ui/welcome.py", line 134, in loadRecentFile
    self.mw.loadProject(act.data())
  File "/home/gedakc/workspace/manuskript.olivierkes/bin/../manuskript/mainWindow.py", line 566, in loadProject
    self.loadDatas(project)
  File "/home/gedakc/workspace/manuskript.olivierkes/bin/../manuskript/mainWindow.py", line 793, in loadDatas
    errors = loadSave.loadProject(project)
  File "/home/gedakc/workspace/manuskript.olivierkes/bin/../manuskript/loadSave.py", line 66, in loadProject
    v1.loadProject(project, zip=isZip)
  File "/home/gedakc/workspace/manuskript.olivierkes/bin/../manuskript/load_save/version_1.py", line 657, in loadProject
    files[os.path.join(p, f)] = fo.read()
  File "/usr/lib/python3.5/codecs.py", line 321, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x80 in position 3131: invalid start byte
----- end snippet -----

There are at least two known situations in which files with
non-unicode characters can arise:

A. The project is on Mac OS X and the operating system automatically
   creates a .DS_Store file.

B. The project is under git version control and contains a .git
   subdirectory.

This enhancement prevents the Manuskript crash on project load by
ignoring all directory and file names that start with a period.
2018-01-14 11:51:50 -07:00
JackXVII fe617f871f Adds moving World items. #219 2018-01-11 23:44:50 +03:00
JackXVII 42bda30331 Fix bug in worldModel
Because of this bug treeView could not properly hide the columns
2018-01-11 22:36:42 +03:00
Olivier Keshavjee 3c140d755f Adds "Sentence mode" to Focus mode. #259 2017-12-15 20:56:40 +01:00
Olivier Keshavjee 19f8938852 Corrects bug in links tooltips 2017-12-15 20:12:51 +01:00
Olivier Keshavjee a6a82d1bba Clickable links: adds tip to tooltip 2017-12-14 15:06:51 +01:00
Olivier Keshavjee cd8ad6cc3a Adds: clickable links, and display images as tooltips (#22, #215) 2017-12-14 14:55:14 +01:00
Olivier Keshavjee e76b9b4a1c Another take on status bar (#262) 2017-12-08 10:20:33 +01:00
Olivier Keshavjee 1764baf292 Fixes a bug introduced when fixing #261 2017-12-06 18:53:42 +01:00
Olivier Keshavjee d521fc0771 Fixes #261: Manuskript response slow with recent addition of focus mode 2017-12-06 18:41:26 +01:00
Olivier Keshavjee 5e2ac47dcc Fixes #260: Organize Menu is not disabled on startup 2017-12-06 08:55:52 +01:00
Olivier Keshavjee 46384b68eb Fixes bugs in focus mode (#259) 2017-12-05 23:45:16 +01:00
Olivier Keshavjee 826d53933f Adds #259: Focus Mode (poke #234) 2017-12-05 23:18:32 +01:00
Olivier Keshavjee 3998ed68d3 Fixes #249: Ctrl+tab gets trapped in Debug tab 2017-12-04 14:50:09 +01:00
Olivier Keshavjee 3cdb2f8f25 Hides Navigation Dock's title bar 2017-12-04 14:18:58 +01:00
Olivier Keshavjee 17f341fe85 Hides debug tab, and fixes #253: French Tab in English Mode 2017-12-04 14:12:00 +01:00
Olivier Keshavjee 25911876eb Fixes #246: Index card status can spillover 2017-12-04 13:52:58 +01:00
Olivier Keshavjee 9cbd8887c7 Fixes #240: Cannot write a summary on a plot resolution step 2017-12-04 13:27:57 +01:00
Olivier Keshavjee 9c635301b5 Adds #223: command line parameter to open project 2017-11-30 17:47:23 +01:00
Olivier Keshavjee ca39121826 UI tweaks 2017-11-30 17:18:53 +01:00
Olivier Keshavjee 92e5c351b7 Adds: smart formatting on keypress 2017-11-30 13:21:40 +01:00
Olivier Keshavjee f3156f5bbd Adds formatting support to MDEditView 2017-11-30 13:12:55 +01:00
Olivier Keshavjee b1192101ce Adds Format menu to mainWindow ui 2017-11-30 11:11:01 +01:00
Olivier Keshavjee 3527f4ad8a Merge branch 'master' into develop 2017-11-30 10:13:25 +01:00
Olivier Keshavjee d32ee37e84 Hopefully last tweaks in context menu (#229) and optimization 2017-11-29 23:16:01 +01:00
Olivier Keshavjee e62b473c47 Adds: settings for applicatoin font size 2017-11-29 14:34:25 +01:00
Olivier Keshavjee 82c24498bb Tweaks Context menu to mirror Edit menu #229 2017-11-29 10:24:07 +01:00
Olivier Keshavjee c504cb510e Fixes fullScreen scrollbar range 2017-11-28 19:58:23 +01:00
Olivier Keshavjee 91989269f1 Fixes a bug in highlighter that makes it slow 2017-11-28 16:28:37 +01:00
Olivier Keshavjee 2b1465a1f3 Adds #175: Typewriter scrolling 2017-11-28 10:26:43 +01:00
Olivier Keshavjee b97cbdc1c3 Fixes a bug: click in treeview background does not deselect any more 2017-11-27 22:41:44 +01:00
Olivier Keshavjee f999d6b33d Fixes bug in welcome: cannot chose template with translation 2017-11-27 22:19:16 +01:00
Olivier Keshavjee cb79e504e7 Merge branch 'master' into develop 2017-11-27 21:53:37 +01:00
Olivier Keshavjee c2dcbf56a0 Adds new markdown highlighter and many little tweaks 2017-11-27 21:35:32 +01:00
Olivier Keshavjee 9baea11791 Fixes FullScreenEditor with MDEditView 2017-11-27 21:13:44 +01:00
Olivier Keshavjee 7b29d332c5 Removes textFormat panel (bold, italic, etc. buttons) 2017-11-27 20:58:02 +01:00
Olivier Keshavjee 79ef970bfd Autohide statusbar 2017-11-27 15:09:07 +01:00
Olivier Keshavjee c1ad771642 Subclass textEditView 2017-11-27 15:00:07 +01:00
Olivier Keshavjee c52df2c90d Changes menu organization #229 2017-11-27 08:05:53 +01:00
Olivier Keshavjee 6193dfe8f5 Adds #233: highlighter for CriticMarkup 2017-11-26 21:23:34 +01:00
Olivier Keshavjee d27ce4dec6 Fixes #232: Add markdown support of other tabs 2017-11-25 14:58:15 +01:00
Olivier Keshavjee 7940cdb336 Adds better fullscreen theme color integration 2017-11-25 14:17:49 +01:00
Olivier Keshavjee 5f76a25f39 Changes title color to something more contrasted 2017-11-25 09:54:10 +01:00
Olivier Keshavjee 59742accfa Moves textedit scrollbar outside the margins 2017-11-24 22:33:12 +01:00
Olivier Keshavjee 52af71757e Adds: better harmonization between Documents menu and context menu #229 2017-11-24 20:50:18 +01:00
Olivier Keshavjee 66f09729b5 Adds duplicate in contexte menu, and fixes a bug in it #229 2017-11-24 18:44:31 +01:00
Olivier Keshavjee 6d98427a2d Fixes UI stuff with Documents menu #229 2017-11-24 18:19:50 +01:00
Olivier Keshavjee 584e75eba4 Updates base translation files, and french translation. 2017-11-24 14:52:32 +01:00
Curtis Gedak 0ff701172d Change "Recents" to "Recent"
See issue #181.
2017-11-23 12:43:31 -07:00
Curtis Gedak af761dcbab Fix sentence structure for Summary Situation help text
See issue #181.
2017-11-23 12:43:31 -07:00
Curtis Gedak a8ed0f5767 Change "informations" to "information"
See issue #181.
2017-11-23 12:43:31 -07:00
Curtis Gedak 6210f63525 Change "Serie" to "Series"
See issue #181.
2017-11-23 12:43:31 -07:00
Olivier Keshavjee 0f49bc7517 Adds #206: Adjusting font size (CTRL+MouseWheelUp/Down) 2017-11-23 18:53:40 +01:00
Olivier Keshavjee c4d4f61702 Fixes highlighter colors, should work in most themes 2017-11-23 18:14:04 +01:00
Olivier Keshavjee 64994cde3a Adds: unit tests and starts refactoring models 2017-11-23 11:03:14 +01:00
Olivier Keshavjee 519d4666cf Updates version number and deb build script. 2017-11-22 22:26:28 +01:00
Olivier Keshavjee da62b823c7 Checkpoint: working highlighter. Optimization welcome. 2017-11-22 21:03:47 +01:00
Olivier Keshavjee 9be2edeee7 Checkpoint: adding new markdown highlighter 2017-11-22 13:43:40 +01:00
Olivier Keshavjee 43c82cb3c9 Adds: simple ui tests for exporter and importer widgets 2017-11-22 11:27:21 +01:00
Olivier Keshavjee 550f889251 Fixes: some Documents menu calls would crash manuskript if in textEdit 2017-11-22 09:37:02 +01:00
Olivier Keshavjee f945387066 Adds unit test for #225: Manuskript fails to run in Ubuntu 14.04 2017-11-22 09:08:54 +01:00
Olivier Keshavjee 6cc8864937 Fixes #225: Manuskript fails to run in Ubuntu 14.04 2017-11-22 08:52:30 +01:00
Olivier Keshavjee ba4fe6b57a Fixes the organizationName issue in #225. 2017-11-21 23:11:08 +01:00
Olivier Keshavjee 8ff046b23b Extends coverage in settingsWindow 2017-11-20 23:26:22 +01:00
Olivier Keshavjee a7f668c2bf Fixes test_settingsWindow and clean up 2017-11-20 22:35:39 +01:00
Olivier Keshavjee b9e35c8709 Adds unit tests for settingWindow 2017-11-20 22:24:47 +01:00
Olivier Keshavjee 9e91fe3f2c Fixes: POV column visibility in outline is always hidden at start 2017-11-20 16:18:25 +01:00
Olivier Keshavjee 9d3b64de8f Adds: references tests, corrects bugs 2017-11-20 15:42:30 +01:00
Olivier Keshavjee 7db2848474 This should build with SemaphoreCI 2017-11-19 17:54:04 +01:00
Olivier Keshavjee f098e74f45 Adds: unit test coverage for outlineItem 2017-11-19 16:03:18 +01:00
Olivier Keshavjee 584b0b04a6 Checkpoint: revisions 2017-11-19 15:29:38 +01:00
Olivier Keshavjee a0fac27e07 Checkpoint: outlineItem tests 2017-11-19 01:36:58 +01:00
Olivier Keshavjee 159e1c3f75 Adds mainWindow and completes function.py coverage 2017-11-19 00:54:11 +01:00
Olivier Keshavjee 1a5fdc7b1f Adds unit tests for functions 2017-11-19 00:20:49 +01:00
Olivier Keshavjee 84466b90e3 Adding unit test 2017-11-18 22:07:10 +01:00
Olivier Keshavjee 04fc6a5ae4 Checkpoint: refactoring 2017-11-18 20:53:10 +01:00
Olivier Keshavjee a42c7a41ab Merge branch 'feature/Exporters' into develop 2017-11-18 18:00:54 +01:00
Olivier Keshavjee ad01de4cd4 Checkpoint in refactoring outlineItem 2017-11-17 12:16:39 +01:00
Olivier Keshavjee cf4c1c83bf Changes every Enum to IntEnum 2017-11-15 21:05:48 +01:00
Olivier Keshavjee 9e95196cc5 Changes Outline enums to IntEnum 2017-11-15 20:58:12 +01:00
Olivier Keshavjee 805d7adaba Starts mirgration from Enum to IntEnum 2017-11-15 20:40:14 +01:00
Olivier Keshavjee bc0d6f5760 Creates base classes 2017-11-15 20:34:05 +01:00
Olivier Keshavjee 170c8ef404 Fixes #194: Editor tab should trim long titles 2017-11-14 18:11:50 +01:00
Olivier Keshavjee 31dcc6d53a Adds better style colors of references 2017-11-14 15:22:16 +01:00
Olivier Keshavjee a334e8bd1b Improves theme desktop integration greatly 2017-11-14 15:01:20 +01:00
Olivier Keshavjee ee212db39c Removes most of hard-coded colors 2017-11-14 14:56:11 +01:00
Olivier Keshavjee 58bdf35953 Adds: transparent text editor 2017-11-14 11:23:18 +01:00
Olivier Keshavjee b0af99eddc Adds default system style to text editor 2017-11-14 10:50:32 +01:00
Olivier Keshavjee 2109f88816 Improves colors of goal progress bar 2017-11-14 10:36:57 +01:00
Olivier Keshavjee 845aa8b205 Improves colors of index card delegate editor 2017-11-14 10:12:07 +01:00
Olivier Keshavjee 0c3f96014a Improves readabily of outline delegate 2017-11-14 10:00:35 +01:00
Olivier Keshavjee cc84f53f04 Improves readabily of tree and card delegate 2017-11-14 09:42:49 +01:00
Olivier Keshavjee ed864eab1e Fixes #213: Program Crash on Import with images 2017-11-14 08:25:23 +01:00
Olivier Keshavjee fd0cd2cd4f Improves the Mind Map importer #208 2017-11-13 22:55:33 +01:00
Olivier Keshavjee c4f8d0da60 Fixes: Missing default file extension when Saving As... #211 2017-11-13 00:51:08 +01:00
Olivier Keshavjee d3e724ccb0 Import: preview after chosing file, and add seting to Mind Map importer #208 2017-11-13 00:45:50 +01:00
Olivier Keshavjee 7b4ba33d15 Adds: MindMap import format #208 2017-11-13 00:32:34 +01:00
Olivier Keshavjee 1aa6afc2bc Fixes: One white pixel visible in full screen mode #210 2017-11-12 20:48:27 +01:00
Olivier Keshavjee 40b07938d0 Corrects a typo. #200 2017-11-11 09:55:36 +01:00
Olivier Keshavjee 4445b55559 Allows pasted items to keep ID if not already in model. 2017-11-10 17:40:59 +01:00
Olivier Keshavjee bb57d3d057 Adds: merge 2017-11-10 17:21:02 +01:00
Olivier Keshavjee a153606811 Adds: split dialog, split at cursor 2017-11-10 16:31:40 +01:00
Olivier Keshavjee 3b17c4e2b4 Adds: Menu Documents. Edit operations (copy, cut, paste, duplicate, remove), and Move up and down. 2017-11-10 11:35:53 +01:00
Olivier Keshavjee bc70501373 Fixes a bug when entering non-digit values for item's goal in metadata 2017-11-09 20:30:54 +01:00
Olivier Keshavjee 15ccaa513b Adds: import documents from several sources (txt, md, html, epub, docx, OPML, odt, etc.) #200 2017-11-09 15:21:25 +01:00
Olivier Keshavjee a231721bdb Adds: ability to split scenes at custom points. #200 2017-11-09 15:18:21 +01:00
Olivier Keshavjee 24607bca59 Adds setting to manage word wrap, and enhances UI. #200 2017-11-09 11:25:24 +01:00
Paweł Świątkowski 0807b14e5c Don't pass none to enchant.dict_exists 2017-11-09 10:45:05 +01:00
Olivier Keshavjee 3cef130bc6 Fixes a strupid bug recentrly introduced in outlineItem.findUniqueID. 2017-11-09 10:40:54 +01:00
Olivier Keshavjee 271f467d0e Adds pandoc wrap option to manage non-semantic linebreaks in imports 2017-11-09 08:46:31 +01:00
Paweł Świątkowski b3ba8e813d Get default locale in more reliable way 2017-11-09 01:44:01 +01:00
Olivier Keshavjee 9c99d186e5 Adds: import with pandoc through either OPML or markdown. #200 2017-11-08 23:46:18 +01:00
Olivier Keshavjee 34b55b511c Adds: support of setext-style headers in markdown import. #200 2017-11-08 23:20:13 +01:00
Olivier Keshavjee bc5c53fe6d Adds: internal markdown importer. #200 2017-11-08 22:54:31 +01:00
Olivier Keshavjee c6391e976c Adds: ability to import from folder structure. #200 2017-11-08 21:35:26 +01:00
Olivier Keshavjee ccf33b3ccf Adds: import from many formats using pandoc. #200 2017-11-07 20:30:39 +01:00
Olivier Keshavjee 9eb1402613 Fixes two small bugs #200. 2017-11-07 16:22:59 +01:00
Olivier Keshavjee a29eddabea Adds: OPML import with preview (using @camstevenson's importer) #200 2017-11-07 15:33:18 +01:00
Olivier Keshavjee fb50d42348 Checkpoint: import now works. 2017-11-07 14:40:46 +01:00
Olivier Keshavjee 543d5a232a Checkpoint: preview seems to work 2017-11-07 14:25:47 +01:00
Olivier Keshavjee 316651245c Checkpoint: opml import can be previewed in tree view 2017-11-07 12:50:40 +01:00
Olivier Keshavjee d51233ebba Cleans treeView of some call to mainWindow that should be here 2017-11-07 12:02:02 +01:00
Olivier Keshavjee 221c7a181d Checkpoint: basic mechanics of settings implemented 2017-11-07 11:25:19 +01:00
Olivier Keshavjee 0a0649a0db Fixes: Manuskript crashes when a wrong locale is set. See #188. 2017-11-06 18:29:18 +01:00
Olivier Keshavjee 340fceeda3 Checkpoint: selecting file working, have to preview and import now. 2017-11-06 18:21:40 +01:00
Olivier Keshavjee b520b12d7a Adds a tip if pandoc is not installed. #190 2017-11-06 10:05:20 +01:00
Olivier Keshavjee 72b44fe90d Fixes docstrings 2017-11-06 09:30:33 +01:00
Olivier Keshavjee 572feb5409 Creates empty import window 2017-11-06 09:16:44 +01:00
Olivier 1f04bf6f54
Merge pull request #192 from camstevenson/import-export
Adds: Import OPML
2017-11-06 08:21:06 +01:00
Cam Stevenson 1fa86ddd73 Finish OPML Import 2017-11-05 08:24:25 -05:00
Olivier Keshavjee 81de19165b Adds a 'Rename Item' option to context menu in the Tree view #189 2017-11-05 13:49:31 +01:00
Olivier Keshavjee fc1bd40c21 Uses instead of (#186) 2017-11-04 08:26:42 +01:00
Olivier Keshavjee 4ddb95ff67 Removes MultiMarkDown exporter. See #186. 2017-11-04 08:01:45 +01:00
Olivier Keshavjee 2cc721674a Fixes: Index card text almost invisible in dark themes. #183 2017-11-02 12:14:45 +01:00
Olivier Keshavjee 701833ed7e Bumps version number 2017-10-31 21:25:27 +01:00