のねのBlog

パソコンの問題や、ソフトウェアの開発で起きた問題など書いていきます。よろしくお願いします^^。

OSS

CharMap

namespace SharpFont.Internal { [StructLayout(LayoutKind.Sequential)] internal class CharMapRec { internal IntPtr face; internal Encoding encoding; internal PlatformId platform_id; internal ushort encoding_id; } } namespace SharpFont { publ…

配列フィールドは ByValArray または SafeArray と組で使用してください。

LPArrayのところで、全て同じエラーになる。 LPArrayをByValArrayに変えると、動くようになる。 読みこむだけなら、これで問題なさそうに思える。 この感じの行があると、マーシャリングができないようだ。 [MarshalAs(UnmanagedType.LPArray, SizeConst = 4…

マーシャリングできません: 無効なマネージ/アンマネージ型の組み合わせです。

以下の試しのコードを実行したところ、マーシャリングのエラーになった。 namespace Examples { public partial class ExampleForm : Form { private void listBoxFont_SelectedIndexChanged(object sender, EventArgs e) { fontFace = new Face(lib, Path.C…

Faceクラス

namespace SharpFont { public sealed class Face : IDisposable { private IntPtr reference; private FaceRec rec; private Library parentLibrary; public Face(Library library, string path, int faceIndex) : this(library) { IntPtr reference; Error…

'System.TypeLoadException'

型 'System.TypeLoadException' のハンドルされていない例外が mscorlib.dll で発生しました 追加情報:型 'SharpFont.TrueType.Internal.HeaderRec' の フィールド 'Created' をマーシャリングできません: 無効なマネージ/アンマネージ型の組み合わせです。 …

GetSfntTable

public object GetSfntTable(SfntTag tag) { IntPtr tableRef = FT.FT_Get_Sfnt_Table(Reference, tag); if (tableRef == IntPtr.Zero) return null; switch (tag) { case SfntTag.Header: return new Header(tableRef); case SfntTag.HorizontalHeader: ret…

CS1591

プロジェクト>プロパティ>ビルド>出力:XMLドキュメントファイルのチェックをはずす。 その設定のファイル名を空にすれば XML コメント出力の機能は Off になります。

FT_GLYPH_FORMAT_COMPOSITE

FT_GLYPH_FORMAT_COMPOSITE The glyph image is a composite of several other images. This format is only used with FT_LOAD_NO_RECURSE, and is used to report compound glyphs (like accented characters). 2453 FT_LOCAL_DEF( FT_Error ) 2454 TT_Loa…

composite glyph

1655 /* otherwise, load a composite! */ 1656 else if ( loader->n_contours == -1 ) 1657 { 1658 FT_UInt start_point; 1659 FT_UInt start_contour; 1660 FT_ULong ins_pos; /* position of composite instructions, if any */ 1661 1662 1663 start_poi…

TT_CONFIG_OPTION_EMBEDDED_BITMAPS

30 #ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS 31 #include "pngshim.c" 32 #include "ttsbit.c" 33 #endif

FT_DEFINE_SFNT_INTERFACE

565 #ifndef FT_CONFIG_OPTION_PIC 566 567 #define FT_DEFINE_SFNT_INTERFACE( \ 568 class_, \ 569 goto_table_, \ 570 init_face_, \ 571 load_face_, \ 572 done_face_, \ 573 get_interface_, \ 574 load_any_, \ 575 load_head_, \ 576 load_hhea_, \ …

ebdt

460 FT_DEFINE_SFNT_INTERFACE( 461 sfnt_interface, 462 tt_face_goto_table, 463 464 sfnt_init_face, 465 sfnt_load_face, 466 sfnt_done_face, 467 sfnt_get_interface, 468 469 tt_face_load_any, 470 471 tt_face_load_head, 472 tt_face_load_hhea, 4…

EBDT

static FT_Error tt_sbit_decoder_load_bitmap( TT_SBitDecoder decoder, FT_UInt glyph_format, FT_ULong glyph_start, FT_ULong glyph_size, FT_Int x_pos, FT_Int y_pos ) { FT_Error error; FT_Stream stream = decoder->stream; FT_Byte* p; FT_Byte* p…

truetype cmap format 2 その2

Freetype2の場合: ※TT_PEAK_USHORTの場合、ポインタの場所を読む。(ポインタは進めない。) ※TT_NEXT_USHORTの場合、ポインタの場所を読み、ポインタを進める。 391 /* return sub header corresponding to a given character code */ 392 /* NULL on inval…

ARG_1_AND_2_ARE_WORDS

if ($flags & self::ARG_1_AND_2_ARE_WORDS) { if ($flags & self::ARGS_ARE_XY_VALUES) { $e = $font->readInt16(); $f = $font->readInt16(); } else { $point_compound = $font->readUInt16(); $point_component = $font->readUInt16(); } } else { if ($…

shape_closure_consumer_t用 main

①ー2:shape_closure_consumer_t用 110 int 111 main (int argc, char **argv) 112 { 113 main_font_text_t<shape_closure_consumer_t, FONT_SIZE_NONE, 0> driver; 114 return driver.main (argc, argv); 115 } ②共通 50 template <typename consumer_t, int default_font_size, int subpixel_bits> 51 struct main_font_text_t…</typename></shape_closure_consumer_t,>

shape_consumer_t用 main

hb_shape_full() at hb-shape.cc:374 0x7ffff7b413df shape_options_t::shape() at options.hh:248 0x4049bc shape_consumer_t<view_cairo_t>::consume_line() at shape-consumer.hh:61 0x4053b2 main_font_text_t<shape_consumer_t<view_cairo_t>, 256, 8>::main() at main-font-text.hh:80 0x4051eb main</shape_consumer_t<view_cairo_t></view_cairo_t>…

shaper list

44 /* hb_face_t */ 47 const hb_face_t _hb_face_nil = { 48 HB_OBJECT_HEADER_STATIC, 50 true, /* immutable */ 52 NULL, /* reference_table_func */ 53 NULL, /* user_data */ 54 NULL, /* destroy */ 56 0, /* index */ 57 1000, /* upem */ 58 0, /* …

./test-version --debug-log

u01@vm01:~/layout/oss/harfbuzz-1.1.2/test/api $ ./test-version --debug-log

./test-unicode --debug-log

u01@vm01:~/layout/oss/harfbuzz-1.1.2/test/api $ ./test-unicode --debug-log

HB_BUFFER_FLAG_BOT

177 typedef enum { /*< flags >*/ 178 HB_BUFFER_FLAG_DEFAULT = 0x00000000u, 179 HB_BUFFER_FLAG_BOT = 0x00000001u, /* Beginning-of-text */ 180 HB_BUFFER_FLAG_EOT = 0x00000002u, /* End-of-text */ 181 HB_BUFFER_FLAG_PRESERVE_DEFAULT_IGNORABLES…

hb_shape

399 void 400 hb_shape (hb_font_t *font, 401 hb_buffer_t *buffer, 402 const hb_feature_t *features, 403 unsigned int num_features) 404 { 405 hb_shape_full (font, buffer, features, num_features, NULL); 406 }

add

hb_buffer_t::add() at hb-buffer.cc:241 0x7ffff7b33f90 hb_buffer_add_utf<hb_utf8_t>() at hb-buffer.cc:1,484 0x7ffff7b36fb5 hb_buffer_add_utf8() at hb-buffer.cc:1,519 0x7ffff7b3629b shape_options_t::populate_buffer() at options.hh:226 0x4048ef shape_co</hb_utf8_t>…

hb-view

template <typename consumer_t, int default_font_size, int subpixel_bits> struct main_font_text_t { main_font_text_t (void) : options ("[FONT-FILE] [TEXT]"), <==デフォルト値 font_opts (&options, default_font_size, subpixel_bits), input (&options), consumer (&options) {} int main (int argc, char **argv)</typename>…

pango_cairo_renderer_show_text_glyphs

424 static void 425 pango_cairo_renderer_show_text_glyphs (PangoRenderer *renderer, 426 const char *text, 427 int text_len, 428 PangoGlyphString *glyphs, 429 cairo_text_cluster_t *clusters, 430 int num_clusters, 431 gboolean backward, 432 …

pango_glyph_string_extents_range

_pango_cairo_font_private_get_glyph_extents_cache_entry() at pangocairo-font.c:791 0x7ffff7773553 _pango_cairo_font_private_get_glyph_extents() at pangocairo-font.c:832 0x7ffff7773553 pango_glyph_string_extents_range() at glyphstring.c:211…

pango-layout_get_pixel_exteents

pango-layout_get_pixel_exteents _pango_engine_shape_shape

pango 1.38.1

pango_cairo_renderer_show_text_glyphs() at pangocairo-render.c:494 0x7ffff777501b pango_cairo_renderer_draw_glyphs() at pangocairo-render.c:526 0x7ffff77754b4 pango_renderer_draw_glyphs() at pango-renderer.c:642 0x7ffff7bb65df pango_render…

pango 1.38.1 pango-view

Program arguments: --font="Garuda 50" test-thai_kigen.txt --output=pv_kigen.pngWorking directory ${workspace_loc:PangoView_1.38.1} Use default

makeエラー

harfbuzzでglibを切ると、pangoでmakeエラーになる u01@vm01:~/layout/oss/pango-1.38.1$ ./configure --prefix=$HOME/usr --enable-debug=yes u01@vm01:~/layout/oss/pango-1.38.1$ make make[2]: Entering directory `/home/u01/layout/oss/pango-1.38.1/p…