eb05362005-11-05Henrik Grubbström (Grubba) /* -*- C -*- */
1a05542005-07-28Martin Nilsson class GTK2.TextTag; inherit G.Object; //! Properties: //! string background //! int background-full-height //! int background-full-height-set //! GDK2.Color background-gdk //! int background-set //! GDK2.Pixmap background-stipple //! int background-stipple-set //! int direction
7caac22014-09-05Chris Angelico //! One of CONST(GTK_TEXT_DIR_)
1a05542005-07-28Martin Nilsson //! int editable //! int editable-set //! string family //! int family-set //! string font require pango; //! Pango.FontDescription font-desc endrequire; //! string foreground //! GDK2.Color foreground-gdk //! int foreground-set //! GDK2.Pixmap foreground-stipple //! int foreground-stipple-set //! int indent //! int indent-set //! int invisible //! int invisible_set //! int justification
7caac22014-09-05Chris Angelico //! One of CONST(GTK_JUSTIFY_)
1a05542005-07-28Martin Nilsson //! int justification-set //! string language; //! int language-set; //! int left-margin; //! int left-margin-set; //! string name; //! int pixels-above-lines; //! int pixels-above-lines-set; //! int pixels-below-lines; //! int pixels-below-lines-set; //! int pixels-inside-wrap; //! int pixels-inside-wrap-set; //! int right-margin; //! int right-margin-set; //! int rise; //! int rise-set; //! float scale; //! int scale-set; //! int size; //! double size-points; //! int size-set; require pango; //! int stretch; //! One of CONST(PANGO_STRETCH) //! int stretch-set; endrequire; //! int strikethrough; //! int strikethrough-set; require pango; //! int style; //! One of CONST(PANGO_STYLE_) //! int style-set; //! Pango.TabArray tabs //! int tabs-set; //! int underline; //! One of CONST(PANGO_UNDERLINE_) //! int underline-set; //! int variant; //! One of CONST(PANGO_VARIANT_) //! int variant-set; endrequire; //! int weight; //! int weight-set; //! int wrap-mode;
7caac22014-09-05Chris Angelico //! One of CONST(GTK_WRAP_)
1a05542005-07-28Martin Nilsson //! int wrap-mode-set; signal event;
3d76632005-11-03Lance Dillon void create(string|mapping(string:mixed) name_or_props)
1a05542005-07-28Martin Nilsson //! Creates a new text tag.
3d76632005-11-03Lance Dillon {
ba9e802006-02-27Martin Stjernholm  pgtk2_verify_not_inited(); pgtk2_verify_setup();
3d76632005-11-03Lance Dillon  {
017b572011-10-28Henrik Grubbström (Grubba)  if (TYPEOF(Pike_sp[-args]) == PIKE_T_STRING) {
3d76632005-11-03Lance Dillon  char *name; GtkTextTag *gt;
96f5f42018-08-05Martin Nilsson  get_all_args(NULL,args,"%s",&name);
3d76632005-11-03Lance Dillon  gt=gtk_text_tag_new(name); THIS->obj=G_OBJECT(gt); } else { INIT_WITH_PROPS(GTK_TYPE_TEXT_TAG); }
ba9e802006-02-27Martin Stjernholm  pgtk2_pop_n_elems(args);
3d76632005-11-03Lance Dillon  }
ba9e802006-02-27Martin Stjernholm  pgtk2__init_this_object();
3d76632005-11-03Lance Dillon }
1a05542005-07-28Martin Nilsson  int get_priority(); //! Gets the tag priority. void set_priority(int priority); //! Sets the priority. Valid priorities start at 0 and go to 1 less //! than W(TextTagTable)->get_size(). int event(G.Object event_object, GDK2.Event event, GTK2.TextIter iter) //! Emits the 'event' signal. {
ba9e802006-02-27Martin Stjernholm  pgtk2_verify_inited();
1a05542005-07-28Martin Nilsson  { struct object *o1,*o2,*o3; int res;
96f5f42018-08-05Martin Nilsson  get_all_args(NULL,args,"%o%o%o",&o1,&o2,&o3);
1a05542005-07-28Martin Nilsson  res=gtk_text_tag_event(GTK_TEXT_TAG(THIS->obj), G_OBJECT(get_gobject(o1)), (GdkEvent *)get_gobject(o2),
ba9e802006-02-27Martin Stjernholm  (GtkTextIter *)get_pg2object(o3,pgtk2_text_iter_program)); pgtk2_pop_n_elems(args);
1a05542005-07-28Martin Nilsson  push_int(res); } }