Made the tooltip show up in the correct place and configuration when using

2000-04-24  Christopher James Lahey  <clahey@helixcode.com>

	* widgets/e-text/e-text.c: Made the tooltip show up in the correct
	place and configuration when using the "max_lines", "anchor"
	(untested), or "justification" arguments.

From a patch by Iain Holmes <ih@csd.abdn.ac.uk>

	* widgets/e-text/e-text-event-processor-emacs-like.c,
	widget/e-text/e-text-event-processor-types.h,
	widgets/e-text/e-text.c, widgets/e-text/e-text.h: Changed C-w and
	C-y to control the X clipboard.  Added double and triple click
	events.

From widgets/e-table/:

2000-04-24  Christopher James Lahey  <clahey@helixcode.com>

	* e-table.c: Fixed some warnings.

svn path=/trunk/; revision=2581
This commit is contained in:
Christopher James Lahey
2000-04-24 13:36:11 +00:00
committed by Chris Lahey
parent 60f56fbbff
commit ef9238e9cc
14 changed files with 441 additions and 64 deletions

View File

@ -56,9 +56,9 @@ static const ETextEventProcessorCommand control_keys[26] =
{ E_TEP_SELECTION, E_TEP_NOP, 0, "" }, /* t */
{ E_TEP_START_OF_LINE, E_TEP_DELETE, 0, "" }, /* u */
{ E_TEP_SELECTION, E_TEP_PASTE, 0, "" }, /* v */
{ E_TEP_BACKWARD_WORD, E_TEP_DELETE, 0, "" }, /* w */
{ E_TEP_SELECTION, E_TEP_DELETE, 0, "" }, /* w */
{ E_TEP_SELECTION, E_TEP_DELETE, 0, "" }, /* x */
{ E_TEP_SELECTION, E_TEP_NOP, 0, "" }, /* y */
{ E_TEP_SELECTION, E_TEP_PASTE, 0, "" }, /* y */
{ E_TEP_SELECTION, E_TEP_NOP, 0, "" } /* z */
};
@ -159,6 +159,20 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
tep_el->mouse_down = TRUE;
}
break;
case GDK_2BUTTON_PRESS:
if (event->button.button == 1) {
command.action = E_TEP_SELECT;
command.position = E_TEP_SELECT_WORD;
command.time = event->button.time;
}
break;
case GDK_3BUTTON_PRESS:
if (event->button.button == 1) {
command.action = E_TEP_SELECT;
command.position = E_TEP_SELECT_ALL;
command.time = event->button.time;
}
break;
case GDK_BUTTON_RELEASE:
if (event->button.button == 1) {
command.action = E_TEP_UNGRAB;
@ -166,6 +180,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
gtk_signal_emit_by_name (GTK_OBJECT (tep), "command", &command);
command.time = event->button.time;
tep_el->mouse_down = FALSE;
command.action = E_TEP_NOP;
} else if (event->button.button == 2) {
command.action = E_TEP_MOVE;
command.position = E_TEP_VALUE;
@ -299,7 +314,7 @@ e_text_event_processor_emacs_like_event (ETextEventProcessor *tep, ETextEventPro
command.string = control_keys[(int) (key.keyval - 'a')].string;
}
if (key.keyval == 'x') {
if (key.keyval == 'x' || key.keyval == 'w') {
command.action = E_TEP_COPY;
command.position = E_TEP_SELECTION;
gtk_signal_emit_by_name (GTK_OBJECT (tep), "command", &command);