Site Map   
Production Standards Open Standards

Misc Contributed Code Library
OA Contribution - Software - ReUse Code
 
Browse Library | New Contribution

Contribution Detail

oaString class enhanced for UTF-8 (Unicode)
Author Forum Language License CoO
John McGehee Browse - Post C++ Common Public License Version 1.0 (shrinkwrap) View CoO
Description:
This contributed code extends the oaString class to support Unicode UTF-8, which can represent virtually every written language in history. A much more thorough oaString unit test is included.

Of course I would like to see this new oaString integrated into OpenAccess.

See http://www.voom.net/internationalization-oastring for a complete explanation.

John McGehee
http://www.voom.net

Versions of this Contribution:

ID Download Version(s) Downloads Date Posted
47   oaStringUTF8-10-12-16.tgz         [oa22.04 (22.04p028) (Member Release Date 2008-09-22) ] 11 2010-12-16 19:16
  README Notes:
            OpenAccess Internationalization with Unicode oaString
                 John McGehee, Voom, Inc. http://www.voom.net
                            December 16, 2010

This contributed code extends the oaString class to support Unicode UTF-8,
which can represent virtually every written language in history.  A much more
thorough oaString unit test is included.

This code matches OpenAccess version oa-22.04p028.

See http://www.voom.net/internationalization-oastring for a complete explanation.

If you send me the .dox file, I will document these functions and send it back
to you.

Naturally I am hoping that this code will be integrated into a future version
of OpenAccess.


Bugs Fixed
----------

Beyond adding Unicode UTF-8 support, I also fixed the following bugs and
enhancementsi and provided unit tests:

Implemented in */oaString*:

Bug 1280 oaString::substr() and oaString::index() do not check for out-of-range
          offset
Bug 1283 oaString::resize() allows size 0, does not terminate truncated strings
Bug 1284 oaString::operator[]() does not check for out-of-range offset
Enh 1190 Add oaString::c_str()


Implemented in */oaFont*:

Bug 1285 oaFont::calcBBox() does not check for out-of-range character value


Implemented in */oaNameSpace*:

Bug 1286 Using characters greater than 127 causes asserts and other problems


All of the above together satisfies this feature request:

Enh 700	Please add wide strings for Asian characters


Installation
------------

I have uploaded a hierarchy of source code files.  Install it in your OpenAccess
source like this:

  # Download oaStringUTF8-12-16-10.tgz

  # Back up /path/to/OpenAccess

  cd /path/to/OpenAccess
  tar xvfz oaStringUTF8-12-16-10.tgz
  cd oa
  make install
  cd test
  make unitTest
  
Add the "OPTMODE=dbg" option to the above make commands if you want to build
and test the debug version.

Versions of a Contribution are set by the owner as the most recent OpenAccess release the contribution was successfully built or tested with.
A contributor can:
  • Update their contribution with a new OA release version of the code.
  • OR Delete a previous version. (Basically replace with a more recent version).




 
Copyright © 2004-2017
Silicon Integration Initiative, Inc (Si2)
All rights reserved
Site Map
How to Get an Account
Contact Si2
Contact Site Admin
Legal Notice/Disclaimer