AkelPad Forum Index AkelPad
Support forum
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Bug reports
Goto page Previous  1, 2, 3 ... 7, 8, 9, 10, 11, 12  Next
 
Post new topic   Reply to topic    AkelPad Forum Index -> Discussion (English)
View previous topic :: View next topic  
Author Message
Instructor
Site Admin


Joined: 06 Jul 2006
Posts: 5163

PostPosted: Wed Nov 14, 2012 6:23 am    Post subject: Reply with quote

KDJ wrote:
Let's do the test: "Cycle search" turn on, search down and up (F3, Shift+F3).
Regular expressions for test:
Code:
^
$
^$
\b
\B
Text for test:
Code:

RegExp test - boundary


Test version
Back to top
View user's profile Send private message Send e-mail
KDJ



Joined: 06 Mar 2010
Posts: 1261
Location: Poland

PostPosted: Wed Nov 14, 2012 5:21 pm    Post subject: Reply with quote

Instructor
Super, now it works better than in all other editors.
Back to top
View user's profile Send private message
KDJ



Joined: 06 Mar 2010
Posts: 1261
Location: Poland

PostPosted: Wed Nov 14, 2012 9:25 pm    Post subject: Reply with quote

A small correction.
If the text is terminated by new line character, the following regular expressions:
^
$
\B
should match up to the end of text.
Back to top
View user's profile Send private message
Instructor
Site Admin


Joined: 06 Jul 2006
Posts: 5163

PostPosted: Thu Nov 15, 2012 4:47 am    Post subject: Reply with quote

KDJ
Test version
Back to top
View user's profile Send private message Send e-mail
KDJ



Joined: 06 Mar 2010
Posts: 1261
Location: Poland

PostPosted: Thu Nov 15, 2012 8:30 pm    Post subject: Reply with quote

Instructor
Well done!
Back to top
View user's profile Send private message
cnnnc



Joined: 12 Jan 2008
Posts: 116
Location: Shantou, China

PostPosted: Tue Nov 20, 2012 6:02 am    Post subject: Replace button not work Reply with quote

AkelPad 4.8.0
OS: XP SP3

I like to convert following:
Code:
acb
dfe
gih

into:
Code:
abc
def
ghi


So I call ReplaceDialog and tpye find:
Code:
^(\w)(\w)(\w)$

replace:
Code:
\1\3\2

Opt: RegExp+Beginning

Then I click "Replace" button, but its action just same as "Find Next" button's.

BTW, the "Replace All" button works OK.
Back to top
View user's profile Send private message Send e-mail
Instructor
Site Admin


Joined: 06 Jul 2006
Posts: 5163

PostPosted: Tue Nov 20, 2012 2:35 pm    Post subject: Reply with quote

cnnnc
Test version
Back to top
View user's profile Send private message Send e-mail
cnnnc



Joined: 12 Jan 2008
Posts: 116
Location: Shantou, China

PostPosted: Wed Nov 21, 2012 12:32 am    Post subject: Reply with quote

Test vision(2012-11-20 20:34) is OK. Thanks!
Back to top
View user's profile Send private message Send e-mail
cnnnc



Joined: 12 Jan 2008
Posts: 116
Location: Shantou, China

PostPosted: Thu Dec 27, 2012 3:45 am    Post subject: Reply with quote

There are 17 chars that StatusUserFormat "%cl:%cH" no show anything, 1 Zero char and 16 Surrogate pair Chars, below is their EscapeValue:
Code:
%00
%uD800%uDC00
%uD840%uDC00
%uD880%uDC00
%uD8C0%uDC00
%uD900%uDC00
%uD940%uDC00
%uD980%uDC00
%uD9C0%uDC00
%uDA00%uDC00
%uDA40%uDC00
%uDA80%uDC00
%uDAC0%uDC00
%uDB00%uDC00
%uDB40%uDC00
%uDB80%uDC00
%uDBC0%uDC00
all of their Hex value is:
Code:
\u0000
\u010000
\u020000
\u030000
\u040000
\u050000
\u060000
\u070000
\u080000
\u090000
\u0a0000
\u0b0000
\u0c0000
\u0d0000
\u0e0000
\u0f0000
\u100000
In order to get the original text, copy the EscapeValue text to AkelPad, run SearchReplace.js, Find:
Code:
(.*)
Replace with:
Code:
return unescape($1);
Options:
Code:
[v]RegExp
[v]MultiLine
[v]Replace with function
(*)Beginning
Then click ReplaceAll.
Well, put caret at the beginning of every line, you will see nothing about the section of "%cl:%cH" on the StateBar.
Back to top
View user's profile Send private message Send e-mail
cnnnc



Joined: 12 Jan 2008
Posts: 116
Location: Shantou, China

PostPosted: Wed Jan 02, 2013 10:01 am    Post subject: Reply with quote

Hmm, I made "%cl" and "%cH" separately not in one block, it seem OK now.

It seems that I found a bug about save file from ULE(Unicode_LE) to GB18030(54936).
In order to get the text to test, please run UnicodeCharGen.js
Code:
// Generate all Unicode characters, including extended characters.

try {
  var hMainWnd=AkelPad.GetMainWnd();
}
catch (oError) {
  WScript.Quit();
}

var oSys     =AkelPad.SystemFunction();
var nAkelEdit=AkelPad.IsAkelEdit();
var hWndEdit =AkelPad.GetEditWnd();

SetRedraw(hWndEdit, false);

var vChar=[];

for (i=0x0000;i<=0x0FFF;i+=1) {
  x=i.toString(16);
  vChar.push(unescape("\%u" + "000".substr(0, 4-x.length)+x));
}

for (i=0x1000;i<=0xD7FF;i+=1) {
  vChar.push(unescape("\%u" + i.toString(16)));
}

for (i=0xE000;i<=0xFFFF;i+=1) {
  vChar.push(unescape("\%u" + i.toString(16)));
}

x=null;
i=null;
CollectGarbage();

// Generate extended characters.
for (i=0xd800;i<=0xDBFF;i+=1) {
  x=i.toString(16);
  for (j=0xDC00;j<=0xDFFF;j+=1) {
    vChar.push(unescape("%u" + x + "%u" + j.toString(16)));
  }
}

x=null;
i=null;
j=null;

SetRedraw(hWndEdit, true);

AkelPad.ReplaceSel(vChar.join("\n"));

vChar=null;
CollectGarbage();


function SetRedraw(hWnd, bRedraw) {
  if (nAkelEdit) {
    AkelPad.SendMessage(hWnd, 3185 /*AEM_LOCKSCROLL*/, 3 /*SB_BOTH*/, !bRedraw);
  }

  AkelPad.SendMessage(hWnd, 11 /*WM_SETREDRAW*/, bRedraw, 0);
  if (bRedraw) {
    oSys.Call("user32::InvalidateRect", hWnd, 0, true);
  }
}
.
Save that into file in ULE codepage.
Then Find "?" without any checkbox. there only one "?" exist. It's OK.
Save as the file in codepage GB18030(54936), then Find "?" again, still OK?
Yes, it seem OK.
Then reopen the file and Find "?" again, you will find that there is 42 general chars and 1024 surrogate pair chars become dirty.

The same save action in BabelPad 6.2.0.3 is OK.

Another bug, I had set the default codepage from GBK(936) to GB18030(54936), and had restarted AkelPad. But when I open a ANSI file autodect, AkelPad open it in GBK(936), even I deleted GBK(936) from filter list.
_____________
AkelPad 4.8.0+
WinXP SP3 ChineseSimplified
Back to top
View user's profile Send private message Send e-mail
Instructor
Site Admin


Joined: 06 Jul 2006
Posts: 5163

PostPosted: Sat Jan 19, 2013 3:16 pm    Post subject: Reply with quote

cnnnc wrote:
It seems that I found a bug about save file from ULE(Unicode_LE) to GB18030(54936).
Test version

Quote:
Another bug, I had set the default codepage from GBK(936) to GB18030(54936), and had restarted AkelPad. But when I open a ANSI file autodect, AkelPad open it in GBK(936), even I deleted GBK(936) from filter list.
Autodetection proceeds with hardcoded codepages you cannot change them.
Back to top
View user's profile Send private message Send e-mail
cnnnc



Joined: 12 Jan 2008
Posts: 116
Location: Shantou, China

PostPosted: Thu Jan 24, 2013 4:47 am    Post subject: Reply with quote

Instructor wrote:
cnnnc wrote:
It seems that I found a bug about save file from ULE(Unicode_LE) to GB18030(54936).

Test version

Yes, the bug is fixed. Thanks!
Back to top
View user's profile Send private message Send e-mail
cnnnc



Joined: 12 Jan 2008
Posts: 116
Location: Shantou, China

PostPosted: Sat Feb 02, 2013 9:13 am    Post subject: Reply with quote

It seems there still a bug about save file from ULE(Unicode_LE) to GB18030(54936).
In order to get the text to test, please run UnicodeCharGen.js but a little change the:
Code:
AkelPad.ReplaceSel(vChar.join("\n "));

Save that into file in ULE codepage.
Then Find "?" without any checkbox. there only one "?" exist. It's OK.
Save as the file in codepage GB18030(54936), then Find "?" again, still OK?
Yes, it seem OK.
Then reopen the file and Find "?" again, you will find that there is 512 surrogate pair chars become dirty. They look rules:
Quote:
\u0101b3 ... \u0109b3
\u0111b3 ... \u0119b3
...
\u10F1B3 ... \u10F9B3


The same save action in BabelPad 6.2.0.3 is OK.

There not only these surrogate pair chars become dirty, some others generated in some other actual cases, but they are not look rules.
_____________
AkelPad 4.8.1+
WinXP SP3 ChineseSimplified
Back to top
View user's profile Send private message Send e-mail
Instructor
Site Admin


Joined: 06 Jul 2006
Posts: 5163

PostPosted: Sat Feb 02, 2013 10:59 am    Post subject: Reply with quote

cnnnc
Test version
Back to top
View user's profile Send private message Send e-mail
cnnnc



Joined: 12 Jan 2008
Posts: 116
Location: Shantou, China

PostPosted: Mon Feb 04, 2013 1:50 am    Post subject: Reply with quote

Instructor wrote:
cnnnc
Test version

This test version still exist bug.
Quote:
\u0101b3 ... \u0109b3
\u0111b3 ... \u0119b3
...
\u10F1B3 ... \u10F9B3
OK now, but there is another 1024 surrogate pair chars become dirty. They look rules:
Quote:
\u0102C5...\u0106C5...\u010AC5...\u010EC5
\u0112C5...\u0116C5...\u011AC5...\u011EC5
...
\u10F2C5...\u10F6C5...\u10FAC5...\u10FEC5
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    AkelPad Forum Index -> Discussion (English) All times are GMT
Goto page Previous  1, 2, 3 ... 7, 8, 9, 10, 11, 12  Next
Page 8 of 12

 
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


SourceForge.net Logo Powered by phpBB © 2001, 2005 phpBB Group