BUG: Toggle Word Wrap

Post your questions and problem reports here

Moderator: kfury77

Forum rules
Please try to follow these guidelines. This will help to receive faster and more accurate response.
  • Check the Support section of the corresponding product first. Chances are you will find your answer there;
  • Do not create new topics for already reported problems. Add your comments to the existing topics instead;
  • Create separate topic for each problem request. Do NOT post a number of non-related problem reports in a single topic;
  • Give your topic a meaningful title. Titles such as "A question," "Bug report" and "Help!" provide others no clue what your message is about;
  • Include the version number of the software you are using;
  • This is not an official customer support helpdesk. If you need a prompt and official response, please contact our support team directly instead. It may take a while until you receive a reply in the forum;
Post Reply
CaliforniaJerry
Posts: 88
Joined: Sat Aug 01, 2009 4:48 am
Location: Mountain View, CA
Contact:

BUG: Toggle Word Wrap

Post by CaliforniaJerry »

WeBuilder v9.5.2.106

When you have two (or more) files open, if you toggle the word wrap option, it only affects the window that has the focus. But when you click on another window, it has not been toggled. The problem is that you end up saving the file with unexpected Newline characters, and a diff (file compare) utility will show differences where there shouldn't be any. Aside from being inconvenient, this is a critical error where it might break portions of code.

Here's the scenario:

You have two or more files open. You set them both to "Word Wrap On". You make changes to both files. You then toggle "Word Wrap Off" while focused in one file window, but not the other, and save both files. The problem is, only one of the files actually toggled the word wrap, the one with the focus when you toggled. The other file gets saved with unintended Newline characters.
CaliforniaJerry
Posts: 88
Joined: Sat Aug 01, 2009 4:48 am
Location: Mountain View, CA
Contact:

Still a Problem Here?

Post by CaliforniaJerry »

It looks like this bug was addressed in WeBuilder 2010.0.0.108 Beta release.

It seems the newline is not being saved when Word Wrap is turned on (as described above); however, I believe there is still inconsistent behavior. Perhaps someone else can confirm this.

When I am editing several files, I select one and turn Options > Word Wrap "On". I expect this to affect all files that are currently open. And if I open another file, I would expect Word Wrap to be on for that file as well.

Then, when I turn Word Wrap "Off", I would expect all files to have Word Wrap "Off" as well.
davenz

Re: BUG: Toggle Word Wrap

Post by davenz »

I am not sure about the bug mentioned as I cannot reproduce with my version but setting word wrap on one tab does not change it on another; that is, not a 'global' option but a 'local' one. The implementation is kinda weird though because when going between wrapped and unwrapped tabs, the word wrap option icon can show 'enabled' when wrap isn't enabled. I know it is a toggle but there is more to it than just the icon. It often takes two clicks to toggle the option, no matter what the icon displays.

I can reproduce it this way:

Have at least two tabs open and turn word wrap 'Off' on both.
Set word wrap 'on' on one tab; (at this point the icon shows 'on')
Go to the other tab and note the word wrap icon is set to 'on' without it being on for this tab (though because this is a toggle we can almost expect this).
Click the word wrap icon for this tab - nothing happens.
Click it again and word wrap changes state.

Not a bug as such but unexpected behaviour I think. I don't know if this was the same in 2008.

Dave.
User avatar
Karlis
Site Admin
Posts: 3605
Joined: Mon Jul 15, 2002 5:24 pm
Location: Riga, Latvia, Europe
Contact:

Re: BUG: Toggle Word Wrap

Post by Karlis »

Since most developers rarely need word-wrap (statistics), the intended behavior is for word wrap to toggle on a per-document basis, however the behavior of the menu button is that it shows what will be used for newly opened documents. so if you enable wordwrap, it will be set for the current document and all newly opened but not the other already opened.

I believe this may be confusing indeed but in practice it seems to work, anyways, we are open to suggestions here. What we would like to avoid is to toggling all open files to workdwrap at once. But we want to keep the option of toggling word wrap for all new documents.
Karlis Blumentals
Blumentals Software
www.blumentals.net
davenz

Re: BUG: Toggle Word Wrap

Post by davenz »

I am happy for it to stay as-is. I can think of no reason to waste valuable coding time - which could be better spent on something else - redoing something that works.

Dave.
User avatar
Karlis
Site Admin
Posts: 3605
Joined: Mon Jul 15, 2002 5:24 pm
Location: Riga, Latvia, Europe
Contact:

Re: BUG: Toggle Word Wrap

Post by Karlis »

Good. But if anybody really hates this behavior and it is causing an inconvenience, suggestions are welcome (as always).
Karlis Blumentals
Blumentals Software
www.blumentals.net
Post Reply