[PATCH] KEncodingProber fixes
kumbayo84 at arcor.de
Mon Mar 23 23:02:29 GMT 2009
On Sonntag 22 März 2009, Wang Hoi wrote:
> I've backported v4 to 4.2 branch,
> And KDE 4.2.2 is about to tag (March 25th)
> i think you'd be hurry if you want your new changes to be backported.
> Amarok2 guys really want to fix these things in 4.2 branch
I think i can almost live with the current state for 4.2.2
The attached (hopefully) low risk patch might be a good idea for 4.2.2 and 4.3.
It renames encodingNameByteArray() to encoding() as suggested by David Faure,
fixes a few comments in the header,
and restores the function of encodingName() !
I looked at the amarok repository from
(is this the right repo?) revision 943487.
From what i see amarok still uses encodingName()
and not the new encodingNameByteArray()
Without this patch encodingName() always returns a NULL string,
now it will likely say UTF-8 for normal text files
(please correct me if i am wrong)
It would be nice if somebody could test amarok and possibly #184769
About the function rename:
If amarok(or another program) somewhere already uses the new encodingNameByteArray()
please do one of the following:
* adjust adjust the program so it compiles with the new function name encoding()
* do not apply the rename function part of this patch and leave the encodingNameByteArray() name
For 4.3 i plan to fix the detectUnicode part of KEncodingProber
and add the unit tests.
I think there is not enough time for this now.
Please apply this patch to KDE trunk (4.3) and backport to 4.2 branch.
[PATCH] rename encodingNameByteArray() to encoding()
Make the old encodingName() function return a useful value again
Fix some typos in documentation
Add @since 4.2.2 to the new encoding() function
> 2009/3/22 Wang Hoi <zealot.hoi at gmail.com>
> > sorry, then you commit the future changes,
> > i just read original, patch v2, then have a glimpse at v4,
> > and compile then test serveral documents in kwrite,
> > then commit it.
> > btw, what's the further work for this patch ?
> > Regards,
> > 2009/3/22 Peter Oberndorfer <kumbayo84 at arcor.de>
> >> On Sonntag 22 März 2009, Wang Hoi wrote:
> >> > Looks ok :)
> >> >
> >> Hi,
> >> why did you apply the v4 version of the patch 5 minutes after saying this
> >> new patch looks OK?
> >> Patch v4 uses a different approach for unicodeTest() than my patch.
> >> And now i have to update my patch again and add/fix the lines that were
> >> removed in v4.
> >> Can we please wait for this to be finished before applying it?
> >> Greetings Peter
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 3913 bytes
Desc: not available
More information about the kde-core-devel