Based on the report by Helmut I have created https://redmine.blackboxframework.org/issues/184.
- Josef
issue-#184 HYPERLINK ignored in RTF import
- Josef Templ
- Posts: 2047
- Joined: Tue Sep 17, 2013 6:50 am
- Josef Templ
- Posts: 2047
- Joined: Tue Sep 17, 2013 6:50 am
Re: issue-#184 HYPERLINK ignored in RTF import
I have prepared a fix for this issue.
See diffs at https://redmine.blackboxframework.org/p ... 5e4e36379b.
There is a little difference to Helmut's proposal.
My approach is to do a full trim (trim left and trim right) of the field instruction.
This also solves the problem with the closing double quote, which is caused by a space
character appended. This way we are independent from any assumption about the
number of spaces appended.
A test version is available from http://blackboxframework.org/unstable/i ... 1.1017.zip.
- Josef
See diffs at https://redmine.blackboxframework.org/p ... 5e4e36379b.
There is a little difference to Helmut's proposal.
My approach is to do a full trim (trim left and trim right) of the field instruction.
This also solves the problem with the closing double quote, which is caused by a space
character appended. This way we are independent from any assumption about the
number of spaces appended.
A test version is available from http://blackboxframework.org/unstable/i ... 1.1017.zip.
- Josef
Re: issue-#184 HYPERLINK ignored in RTF import
Josef,
perfect solution. You kill two birds with one stone.
About my problem with html (cut & paste from browser to BlackBox): Is there also a simple solution that the hyperlink is copied too? Other formatting I currently don't care.
- Helmut
perfect solution. You kill two birds with one stone.
About my problem with html (cut & paste from browser to BlackBox): Is there also a simple solution that the hyperlink is copied too? Other formatting I currently don't care.
- Helmut
- Josef Templ
- Posts: 2047
- Joined: Tue Sep 17, 2013 6:50 am
Re: issue-#184 HYPERLINK ignored in RTF import
As far as I know, there is currently only the path over RTF import.Zinn wrote:Josef,
About my problem with html (cut & paste from browser to BlackBox): Is there also a simple solution that the hyperlink is copied too? Other formatting I currently don't care.
- Helmut
Importing html directly would require an html data converter.
If you already have an html file converter it should be possible to
use that as a foundation of a data converter. You mainly have to strip off the
preceding html fragment description.
- Josef
- Josef Templ
- Posts: 2047
- Joined: Tue Sep 17, 2013 6:50 am
Re: issue-#184 HYPERLINK ignored in RTF import
Are there any further comments on this issue?
One comment from my side is this:
I have added the Trim procedure to HostTextConv, where it is needed for the fix.
An obvious alternative would be to add it to module Strings.
This would be a general purpose feature then.
Since there are more procedures (e.g. TrimLeft, TrimRight, StartsWith, EndsWith, Match) that could be added to
Strings, I tried to keep the changes at a minimum for now and avoid the discussion on Strings extensions.
- Josef
One comment from my side is this:
I have added the Trim procedure to HostTextConv, where it is needed for the fix.
An obvious alternative would be to add it to module Strings.
This would be a general purpose feature then.
Since there are more procedures (e.g. TrimLeft, TrimRight, StartsWith, EndsWith, Match) that could be added to
Strings, I tried to keep the changes at a minimum for now and avoid the discussion on Strings extensions.
- Josef
Re: issue-#184 HYPERLINK ignored in RTF import
I have no particular comments. I do occasionally use RTF export, but probably never use RTF import!Josef Templ wrote:Are there any further comments on this issue?
I noticed that Trim looked a little out of place for a potentially generally useful function, but agree that moving it is a separate, and for me not urgent, discussion.
Re: issue-#184 HYPERLINK ignored in RTF import
I am also quite unemotional about it here.
what about starting with a module StringUtils, which can be extended in the future with other general useful string utilities collecting them from places where these are used. I currently cannot foresee how much this would add at load time vs. saved lines of duplicated code. I also see that this might start lengthy discussions about what sould be included and what not, so I would say: go agead with it ...An obvious alternative would be to add it to module Strings.
This would be a general purpose feature then.