Zeus IDE Forum Index Zeus IDE
Use this forum to ask for help, submit a bug report or make a suggestion.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

\n

 
Post new topic   Reply to topic    Zeus IDE Forum Index -> Reporting a Bug
View previous topic :: View next topic  
Author Message
AlanStewart



Joined: 02 Jun 2006
Posts: 77

PostPosted: Sat Mar 29, 2008 8:39 pm    Post subject: \n Reply with quote

I have a registered version of 3.96o, which I just recently upgraded to via the usual way of overwriting over my 3.96n version of Zeus. I finally got around to trying out the new and improved \n support and noticed something a little odd, for me at least.

I was searching for instances of "<br>\n" and replacing them with "" (ie, getting rid of the lines I no longer wanted). Normally I would've expected that the lines would just disappear (what I wanted) but , because the line above the <br> is indented, I noticed that the line *below* the <br> ends up indented as well, after the replacement. I strongly suspect that this has to do with the smart indenting being a little too over-zealous in doing its job.

Let's see if I can do an example:
Code:
   xhtml_code
      text
   <br>
   more_code


What I want to see is:
Code:
   xhtml_code
      text
   more_code


What I'm seeing is:
Code:
   xhtml_code
      text
      more_code


Hope that helps?
Back to top
View user's profile Send private message
jussij
Site Admin


Joined: 13 Aug 2004
Posts: 2191

PostPosted: Mon Mar 31, 2008 12:27 am    Post subject: Reply with quote

Hi Alan,
Quote:
I strongly suspect that this has to do with the smart indenting being a little too over-zealous in doing its job.

The search and replace has in fact work correctly, since you did not include the leading white space in the search.

The correct search string should have been: <br>\n[ ]+ Wink

But you have indirectly found a bug in the Zeus 3.96o beta, since the <br>\n[ ]+ search string was not being handled correctly by the beta version Sad

This bug will be fixed in the official Zeus 3.96o release, due shortly Wink

Cheers Jussi
Back to top
View user's profile Send private message Send e-mail
jussij
Site Admin


Joined: 13 Aug 2004
Posts: 2191

PostPosted: Mon Mar 31, 2008 11:46 pm    Post subject: Reply with quote

The latest Zeus patch fixes this bug and it can be found here: http://www.zeusedit.com/forum/viewtopic.php?t=1790

Cheers Jussi
Back to top
View user's profile Send private message Send e-mail
AlanStewart



Joined: 02 Jun 2006
Posts: 77

PostPosted: Tue Apr 01, 2008 4:58 am    Post subject: Reply with quote

I *think* it's working now. Hard to say since my original request was buggy to begin with.

What I was searching for and replacing was actually working. The indenting I thought I was seeing was from the leading spaces no being removed. So that's all cool.

I did try searching for " +<br>\n" and replacing with "" and that gave me the results that I was expecting. However, this worked even *without* turning on the "Use Regular Expression" checkbox.

Also, because I left the "Replace with" box "empty" (ie. nothing in there), whenever I *next* open up the dialong box, the "Replace with" value is set to something that *isn't* "" and so I have to be extra vigilant that I don't do a global search'n'replace for "<br>" with "img".
Back to top
View user's profile Send private message
jussij
Site Admin


Joined: 13 Aug 2004
Posts: 2191

PostPosted: Tue Apr 01, 2008 5:40 am    Post subject: Reply with quote

Quote:
so I have to be extra vigilant that I don't do a global search'n'replace for "<br>" with "img".

If you did manage to run an incorrect replace all you can always just undo the last change made. No matter how many changes get made by the replace all, they will all be grouped, so they can all be undone by the single undo command Wink

FWIW one of the habits I uses is to tick the repeat find on replace option and when I need to do a replace all I usually run a find, followed by a replace, followed by a replace all. I find this an easy way to check that the search and replace details have been defined correctly Wink

Cheers Jussi
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    Zeus IDE Forum Index -> Reporting a Bug All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group