1693N/A/*
1693N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
1693N/A *
1693N/A * This code is free software; you can redistribute it and/or modify it
1693N/A * under the terms of the GNU General Public License version 2 only, as
2362N/A * published by the Free Software Foundation. Oracle designates this
1693N/A * particular file as subject to the "Classpath" exception as provided
2362N/A * by Oracle in the LICENSE file that accompanied this code.
1693N/A *
1693N/A * This code is distributed in the hope that it will be useful, but WITHOUT
1693N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
1693N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
1693N/A * version 2 for more details (a copy is included in the LICENSE file that
1693N/A * accompanied this code).
1693N/A *
1693N/A * You should have received a copy of the GNU General Public License version
1693N/A * 2 along with this work; if not, write to the Free Software Foundation,
1693N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
1693N/A *
2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
2362N/A * or visit www.oracle.com if you need additional information or have any
2362N/A * questions.
1693N/A *
1693N/A */
1693N/A
1693N/A#ifndef __LESTANDALONE
1693N/A#define __LESTANDALONE
1693N/A
3171N/A#ifndef U_COPYRIGHT_STRING
3171N/A#define U_COPYRIGHT_STRING " (C) Copyright IBM Corp and Others. 1998-2010 - All Rights Reserved"
3171N/A#endif
3171N/A
3171N/A/* ICU Version number */
3171N/A#ifndef U_ICU_VERSION
3171N/A#define U_ICU_VERSION "4.6"
3171N/A#endif
3171N/A
1693N/A/* Definitions to make Layout Engine work away from ICU. */
1693N/A#ifndef U_NAMESPACE_BEGIN
1693N/A#define U_NAMESPACE_BEGIN
1693N/A#endif
1693N/A
1693N/A#ifndef U_NAMESPACE_END
1693N/A#define U_NAMESPACE_END
1693N/A#endif
1693N/A
1693N/A/* RTTI Definition */
1693N/Atypedef const char *UClassID;
1693N/A#ifndef UOBJECT_DEFINE_RTTI_IMPLEMENTATION
1693N/A#define UOBJECT_DEFINE_RTTI_IMPLEMENTATION(x) UClassID x::getStaticClassID(){static char z=0; return (UClassID)&z; } UClassID x::getDynamicClassID() const{return x::getStaticClassID(); }
1693N/A#endif
1693N/A
1693N/A/* UMemory's functions aren't used by the layout engine. */
1693N/Astruct UMemory {};
1693N/A/* UObject's functions aren't used by the layout engine. */
1693N/Astruct UObject {};
1693N/A
1693N/A/* String handling */
1693N/A#include <stdlib.h>
1693N/A#include <string.h>
1693N/A
1693N/A/**
1693N/A * A convenience macro to test for the success of a LayoutEngine call.
1693N/A *
1693N/A * @stable ICU 2.4
1693N/A */
1693N/A#define LE_SUCCESS(code) ((code)<=LE_NO_ERROR)
1693N/A
1693N/A/**
1693N/A * A convenience macro to test for the failure of a LayoutEngine call.
1693N/A *
1693N/A * @stable ICU 2.4
1693N/A */
1693N/A#define LE_FAILURE(code) ((code)>LE_NO_ERROR)
1693N/A
1693N/A
1693N/A#ifndef _LP64
1693N/Atypedef long le_int32;
1693N/Atypedef unsigned long le_uint32;
1693N/A#else
1693N/Atypedef int le_int32;
1693N/Atypedef unsigned int le_uint32;
1693N/A#endif
1693N/A
1693N/A#define HAVE_LE_INT32 1
1693N/A#define HAVE_LE_UINT32 1
1693N/A
1693N/Atypedef unsigned short UChar;
1693N/Atypedef le_uint32 UChar32;
1693N/A
1693N/Atypedef short le_int16;
1693N/A#define HAVE_LE_INT16 1
1693N/A
1693N/Atypedef unsigned short le_uint16;
1693N/A#define HAVE_LE_UINT16
1693N/A
1693N/Atypedef signed char le_int8;
1693N/A#define HAVE_LE_INT8
1693N/A
1693N/Atypedef unsigned char le_uint8;
1693N/A#define HAVE_LE_UINT8
1693N/A
1693N/Atypedef char UBool;
1693N/A
1693N/A/**
1693N/A * Error codes returned by the LayoutEngine.
1693N/A *
1693N/A * @stable ICU 2.4
1693N/A */
1693N/Aenum LEErrorCode {
1693N/A /* informational */
1693N/A LE_NO_SUBFONT_WARNING = -127, // U_USING_DEFAULT_WARNING,
1693N/A
1693N/A /* success */
1693N/A LE_NO_ERROR = 0, // U_ZERO_ERROR,
1693N/A
1693N/A /* failures */
1693N/A LE_ILLEGAL_ARGUMENT_ERROR = 1, // U_ILLEGAL_ARGUMENT_ERROR,
1693N/A LE_MEMORY_ALLOCATION_ERROR = 7, // U_MEMORY_ALLOCATION_ERROR,
1693N/A LE_INDEX_OUT_OF_BOUNDS_ERROR = 8, //U_INDEX_OUTOFBOUNDS_ERROR,
1693N/A LE_NO_LAYOUT_ERROR = 16, // U_UNSUPPORTED_ERROR,
1693N/A LE_INTERNAL_ERROR = 5, // U_INTERNAL_PROGRAM_ERROR,
1693N/A LE_FONT_FILE_NOT_FOUND_ERROR = 4, // U_FILE_ACCESS_ERROR,
1693N/A LE_MISSING_FONT_TABLE_ERROR = 2 // U_MISSING_RESOURCE_ERROR
1693N/A};
1693N/A#define HAVE_LEERRORCODE
1693N/A
1693N/A#define U_LAYOUT_API
1693N/A
1693N/A#define uprv_malloc malloc
1693N/A#define uprv_free free
1693N/A#define uprv_memcpy memcpy
1693N/A#define uprv_realloc realloc
1693N/A
1693N/A#if !defined(U_IS_BIG_ENDIAN)
1693N/A #ifdef _LITTLE_ENDIAN
1693N/A #define U_IS_BIG_ENDIAN 0
1693N/A #endif
1693N/A#endif
1693N/A
1693N/A#endif