Ejemplo n.º 1
0
        public InsertAction(Gtk.TextIter start,
                            string text,
                            int length,
                            ChopBuffer chop_buf)
        {
            this.index = start.Offset - length;
            // GTKBUG: No way to tell a 1-char paste.
            this.is_paste = length > 1;

            Gtk.TextIter index_iter = start.Buffer.GetIterAtOffset(index);
            this.chop = chop_buf.AddChop(index_iter, start);
        }
Ejemplo n.º 2
0
        public EraseAction(Gtk.TextIter start_iter,
                           Gtk.TextIter end_iter,
                           ChopBuffer chop_buf)
        {
            this.start  = start_iter.Offset;
            this.end    = end_iter.Offset;
            this.is_cut = end - start > 1;

            Gtk.TextIter insert =
                start_iter.Buffer.GetIterAtMark(start_iter.Buffer.InsertMark);
            this.is_forward = insert.Offset <= start;

            this.chop = chop_buf.AddChop(start_iter, end_iter);
        }
Ejemplo n.º 3
0
		public EraseAction (Gtk.TextIter start_iter,
		                    Gtk.TextIter end_iter,
		                    ChopBuffer chop_buf)
		{
			this.start = start_iter.Offset;
			this.end = end_iter.Offset;
			this.is_cut = end - start > 1;

			Gtk.TextIter insert =
			        start_iter.Buffer.GetIterAtMark (start_iter.Buffer.InsertMark);
			this.is_forward = insert.Offset <= start;

			this.chop = chop_buf.AddChop (start_iter, end_iter);
		}
Ejemplo n.º 4
0
		public InsertAction (Gtk.TextIter start,
		                     string text,
		                     int length,
		                     ChopBuffer chop_buf)
		{
			this.index = start.Offset - length;
			// GTKBUG: No way to tell a 1-char paste.
			this.is_paste = length > 1;

			Gtk.TextIter index_iter = start.Buffer.GetIterAtOffset (index);
			this.chop = chop_buf.AddChop (index_iter, start);
		}