Commit Graph

21 Commits

Author SHA1 Message Date
2685fe29b1
Code quality improvements 2017-06-24 12:13:35 +02:00
171bc83ec0
HTML parser fix
- URLs followed with space were broken
2017-02-28 22:47:56 +01:00
e9899743ef
Typos, formatting, obsolete imports 2017-02-22 15:09:36 +01:00
266d8eba1f
SafeHTMLParser unicode / subprocess
- don't do subprocess in SafeHTMLParser, it doesn't work in frozen mode
  and an attempt to fix it would take too much refactoring and I'm not
  even sure it would work
- instead, make it handle broken unicode correctly
- I think the previous reports of freezes were caused by trying to
  interpret data as unicode, causing a crash
- it does about 1MB/s on my machine, so a timeout is not a big problem
2017-02-22 09:05:05 +01:00
2cc4435cfc
Imports, typos, syntax errors
- remove obsolete imports
- add missing imports
- fix typos
- fix syntax errors
- thanks to landscape.io for report
2017-02-08 14:19:02 +01:00
59f3a2fbe7
Reduce cyclic dependencies
- rearranged code to reduce cyclic dependencies
- doCleanShutdown is separated in shutdown.py
- shared queues are separated in queues.py
- some default values were moved to defaults.py
- knownnodes partially moved to knownnodes.py
2017-02-08 13:41:56 +01:00
54e3465575
HTML parser queue flush fix
- the queue wasn't correctly flushed
2016-11-14 20:19:26 +01:00
5c9bfe09a2
Parser queue flushing
- the parser queue wasn't flushed when there's an exception resulting in
  the wrong message being displayed selected
2016-10-27 23:09:31 +02:00
671f321ead
HTML parser fix
- the UTF-8-ifying of tags had missing brackets
2016-10-23 18:35:20 +02:00
c335ef7d10
HTML parser fix
- sometimes, a tag attribute name is UTF-8, sometimes it isn't. This
  change makes it handle both
2016-10-23 09:02:27 +02:00
47e2df86b9
Freezing message parser fix #2
- this has been tested on Windows as well, and has been cleaned up.
  There is now a permanent parser thread, and it restarts when the
  parsing takes more than 1 second
- Fixes #900
2016-10-22 01:45:32 +02:00
8f194296e7
Long message parsing fix
- while 448ceaa74c fixed slow rendering on
  windows, there was still a bug where overly long messages caused
  freezeing of the hyperlink regexp parser, which appears to happen on
  all platforms. Maybe it's a freeze, maybe it just takes too long. This
  patch aborts the regexp parser after 1 second and simply displays the
  message without hyperlinks being clickable. This doesn't affect HTML
  mode because there the links are kept as they are
- Fixes #900
2016-10-21 15:54:02 +02:00
c5363c3c5e Add bitcoin URI handler for message viewer 2016-05-02 15:00:24 +02:00
mailchuck
2adafdaadc Improved URI detector 2016-05-02 15:00:24 +02:00
96a1726426 Clickable email and http links in plain text
Email addresses and URIs are now clickable when viewing a message in
plain text mode. Clicking an email address moves to the Send tab, while
clicking an URI has the same result as clicking an URI in html mode, it
will ask for confirmation before opening it in external handler.
2016-05-02 15:00:24 +02:00
f27ca0d3d6 HTML parser updates
HTML parser wasn't correctly handling img tags.
Now it also by defaults disabled external schemas to prevent
deanonymisation (even though the renderer actually doesn't support
external schemas at the moment)

Addresses #178
2016-05-02 15:00:24 +02:00
mailchuck
d36d6f300e Message body display handling of spaces
After the changes in the message body renderer, spaces were not
correctly handled. Fixes #168
2016-05-02 15:00:23 +02:00
mailchuck
ea37913ff1 Html parser fixes
Raw mode improved, avoid HTML parser entirely and just replaces some
strings.
2016-05-02 15:00:22 +02:00
mailchuck
7ef94b446d Lazy rendering of message contents
Message will render as user is scrolling down. This prevents interface
freezes on long messages (such as inline img in text mode). Fixes
Bitmessage##366

Also a minor fix in text mode rendering.
2016-05-02 15:00:22 +02:00
mailchuck
6557681a6c Message has safe link opening
Links in message body (if in HTML mode) now open, but it asks for a
confirmation in a dialog box.

Fixes #27
2016-05-02 15:00:22 +02:00
mailchuck
751f9108d8 HTML detector and switcher
HTML messages are detected and if present, the top of the message
textedit displays a clickable area that switches HTML rendering on and
off.

Fixes #13
2016-05-02 15:00:22 +02:00