瀏覽代碼

* patch from Ido Kanner adding BiDi related functions, Mantis 16269

git-svn-id: trunk@15142 -
marco 15 年之前
父節點
當前提交
ab551a2662

+ 2 - 0
packages/gtk2/src/pango/pango-context.inc

@@ -47,6 +47,8 @@ function pango_context_get_base_dir(context:PPangoContext):TPangoDirection; cdec
   }
 function pango_itemize(context:PPangoContext; text:Pchar; start_index:longint; length:longint; attrs:PPangoAttrList;
            cached_iter:PPangoAttrIterator):PGList; cdecl; external pangolib;
+
+
 {$endif read_interface_functions}
 
 //------------------------------------------------------------------------------

+ 5 - 4
packages/gtk2/src/pango/pango-types.inc

@@ -20,10 +20,11 @@
 
    PPangoDirection = ^TPangoDirection;
    TPangoDirection = (
-     PANGO_DIRECTION_LTR,
-     PANGO_DIRECTION_RTL,
-     PANGO_DIRECTION_TTB_LTR,
-     PANGO_DIRECTION_TTB_RTL
+     PANGO_DIRECTION_LTR,      // A strong left-to-right direction
+     PANGO_DIRECTION_RTL,      // A strong right-to-left direction
+     PANGO_DIRECTION_TTB_LTR,  // A weak left-to-right direction
+     PANGO_DIRECTION_TTB_RTL,  // A weak right-to-left direction
+     PANGO_DIRECTION_NEUTRAL   // No direction specified
    );
 {$ENDIF read_interface_types}
 

+ 2 - 0
packages/gtk2/src/pango/pangoutils.pas

@@ -100,6 +100,8 @@ function pango_get_lib_subdirectory:Pchar; cdecl; external pangolib;
   }
 
 function pango_log2vis_get_embedding_levels(str:Pgunichar; len:longint; pbase_dir:PPangoDirection; embedding_level_list:Pguint8):gboolean; cdecl; external pangolib;
+function pango_unichar_direction(ch : gunichar) : TPangoDirection; cdecl; external pangolib;
+function pango_find_base_dir(text : Pgchar; aLength : gint) : TPangoDirection; cdecl; external pangolib;
 function pango_get_mirror_char(ch:gunichar; mirrored_ch:Pgunichar):gboolean; cdecl; external pangolib;
 function pango_language_get_sample_string(language:PPangoLanguage):Pchar; cdecl; external pangolib;