ADRIFT Forum


The place to discuss the ADRIFT Interactive Fiction toolkit

Somehow Html-markup gets added to text box sometimes?

This forum is the place to learn about and discuss ADRIFT 5. Feel free to mention any bugs you find here, but please also add these to the Bugs & Enhancements list.

Please also refer to the ADRIFT 5 Wiki for more information.

Somehow Html-markup gets added to text box sometimes?

Postby DazaKiwi » Thu Apr 14, 2016 11:48 pm

I am wondering if this is suppose to be a feature or a bug, when you go to edit some expressions or descriptions and *how* it happens i am not exactly sure, but maybe double click after pasting in some code/text?? tried to replicate it but can't but it has happened to me a few times in the past and today that im posting about it. What happens when whatever triggers it is; you suddenly have all the html markup added to the text box around your code/text probably in its true form. What i was doing around about when this happened, I was deleting a key in an expression and then using the drop down menu selecting a new property key.

So it looks like this. Some of the bottom text - half of a line was layered on top of one another, which i couldn't highlight at first. Then it corrected it self when i tried to highlight it specifically, and could see the bottom layer clearly when highlighted.

adrift Code: Select all
<font color="DarkBlue">&lt;<b><font color="Purple">del</font></b>&gt;</font><font color="DodgerBlue"><font color="#FF1E90FF">&lt;#IF(%object%.Children.dazKindofknif.Count&gt;1,&quot; &quot;&amp;%NumberAsText[%object%.Children.dazKindofknif.Count]%&amp;&quot; &quot;,&quot; &quot;)#&gt;</font><font color="#FF1E90FF">&lt;#if(%object%.Children.dazFootprints.Count]%&amp;&quot; &quot;,&quot; &quot;)#&gt;</font><font color="#FF1E90FF">&lt;#if(%object%.Children.dazFootprints.Count=1,&quot;&quot;&amp;%object%.Children.dazKindofknif.List(False,Indefinite)&amp;&edsp;&edsp;&quot;&quot;,&quot;knives<span style="color:White; background-color:#3399ff;">&quot;)#&gt;</font></span></font>


If you click on 'apply' it stays there, so you have to click on cancel to revert back, which means loosing your edits within the text box, other alt description aren't affected just whatever text box you are working in. So in future i will click 'apply' after every single edit i make in case this happens again.

Has anyone else encountered this problem?

*update*
I think i can replicate what is happening now. If you press ctrl+z (usual undo hotkey in most programs and editors. I keep forgetting Adrift doesn't have an undo) now if you double click somewhere on the text box space, the last bit of text in the display gets highlighted (something like the last 6 characters) then the html markup infects the whole text box.
I went into several other alt desc text boxes and just doubled clicked anywhere and the same thing was happening. So perhaps ctrl-z is the trigger for this?

Also it would be nice to be able to have undo and redo in the developer at some point.
http://www.adrift.co/bug/8245
Last edited by DazaKiwi on Fri Apr 15, 2016 1:15 am, edited 1 time in total.
User avatar
DazaKiwi
 
Posts: 530
Joined: Thu Oct 21, 2010 9:05 am
Location: New Zealand
Points: 16

Re: Somehow Html-markup gets added to text box sometimes?

Postby saabie » Fri Apr 15, 2016 12:59 am

I have had this happen a couple of times, usually when my hand slips while I am moving text around with the mouse,
But no matter what I do I can't reproduce it deliberately.
I think it only happens if you have syntax highlighting in the text box (and maybe font tags?), and it has something to do with dragging text or double clicking while the mouse is moving quickly?
saabie
 
Posts: 922
Joined: Fri Aug 12, 2011 2:07 am
Location: Adelaide, South Australia
Points: 25

Re: Somehow Html-markup gets added to text box sometimes?

Postby DazaKiwi » Fri Apr 15, 2016 1:18 am

saabie wrote:I have had this happen a couple of times, usually when my hand slips while I am moving text around with the mouse,
But no matter what I do I can't reproduce it deliberately.
I think it only happens if you have syntax highlighting in the text box (and maybe font tags?), and it has something to do with dragging text or double clicking while the mouse is moving quickly?


saabie can you try replicating it by pressing ctrl-z and then double clicking in the text box, just curious if it is a definite trigger? i think i have also triggered it in the past by accidentally dragging highlighted text as well.
User avatar
DazaKiwi
 
Posts: 530
Joined: Thu Oct 21, 2010 9:05 am
Location: New Zealand
Points: 16

Re: Somehow Html-markup gets added to text box sometimes?

Postby saabie » Fri Apr 15, 2016 2:27 am

The only thing ctrl-z does for me is undo any changes made with the keyboard.
It does not always undo changes made with the mouse though, so if you make changes with both and then press ctrl-z it could get confused.
I could not trigger the bug though.
saabie
 
Posts: 922
Joined: Fri Aug 12, 2011 2:07 am
Location: Adelaide, South Australia
Points: 25

Re: Somehow Html-markup gets added to text box sometimes?

Postby DazaKiwi » Fri Apr 15, 2016 4:47 am

I just had another test, ctrl-z does undo, im sure when i was having this issue it wasn't undoing at all which lead me to think you can't undo (but no redo) but as you said maybe the dev could get confused. I couldn't get it to replicate either with just entering text in the box area and double clicking, however when i wrote an expression, then it was doing it again with just double clicking anywhere in the text box. Tried just font tags only and couldn't replicate it. So it looks like this might be local to embedded expressions.

I will write this up as a bug. But you you could confirm embedded expressions is the culprit i can add that in my post.
User avatar
DazaKiwi
 
Posts: 530
Joined: Thu Oct 21, 2010 9:05 am
Location: New Zealand
Points: 16

Re: Somehow Html-markup gets added to text box sometimes?

Postby ElliotM » Fri Apr 15, 2016 5:20 am

I have seen that as well, but it has been awhile.
ElliotM
 
Posts: 1227
Joined: Tue Apr 17, 2007 8:04 pm
Location: The Midwest in the USA
Points: 13

Re: Somehow Html-markup gets added to text box sometimes?

Postby saabie » Fri Apr 15, 2016 7:03 am

OK, I can repeatedly cause the bug if I select the <# or the #> of an embedded expression (either by double clicking on them, or with the mouse) and then if I click on the selected text it shows all of the hidden formatting commands.
IF BOTH the <# and the #> are highlighted at the same time then the bug does not occur.
saabie
 
Posts: 922
Joined: Fri Aug 12, 2011 2:07 am
Location: Adelaide, South Australia
Points: 25

Re: Somehow Html-markup gets added to text box sometimes?

Postby DazaKiwi » Fri Apr 15, 2016 9:49 pm

Okay thanks for confirming that saabie. I have written up a bug report about it;http://www.adrift.co/bug/19093
User avatar
DazaKiwi
 
Posts: 530
Joined: Thu Oct 21, 2010 9:05 am
Location: New Zealand
Points: 16


Return to ADRIFT 5.0

Who is online

Users browsing this forum: No registered users and 5 guests