mirror of
https://github.com/gryf/wmaker.git
synced 2026-02-11 03:05:52 +01:00
fixed vertical positioning of text
This commit is contained in:
@@ -42,9 +42,6 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define TEXT_SHIFT -4 /* Move the text up relative to the bottom of
|
|
||||||
* the text-box */
|
|
||||||
#if 0
|
#if 0
|
||||||
# define ENTER(X) fprintf(stderr,"Entering: %s()\n", X);
|
# define ENTER(X) fprintf(stderr,"Entering: %s()\n", X);
|
||||||
# define LEAVE(X) fprintf(stderr,"Leaving: %s()\n", X);
|
# define LEAVE(X) fprintf(stderr,"Leaving: %s()\n", X);
|
||||||
@@ -344,8 +341,7 @@ textRefresh( WTextInput *wtext )
|
|||||||
|
|
||||||
/* Draw the text normally */
|
/* Draw the text normally */
|
||||||
WMDrawString(wtext->core->screen_ptr->wmscreen, wtext->core->window,
|
WMDrawString(wtext->core->screen_ptr->wmscreen, wtext->core->window,
|
||||||
wtext->regGC, wtext->font,
|
wtext->regGC, wtext->font, x1, y1, ptr, wtext->text.length);
|
||||||
x1, y2+TEXT_SHIFT, ptr, wtext->text.length);
|
|
||||||
|
|
||||||
/* Draw the selected text */
|
/* Draw the selected text */
|
||||||
if( wtext->text.startPos != wtext->text.endPos )
|
if( wtext->text.startPos != wtext->text.endPos )
|
||||||
@@ -377,7 +373,7 @@ textRefresh( WTextInput *wtext )
|
|||||||
/* Draw the selected text... use invGC so it will be the
|
/* Draw the selected text... use invGC so it will be the
|
||||||
* opposite color as the filled rectangle */
|
* opposite color as the filled rectangle */
|
||||||
WMDrawString(wtext->core->screen_ptr->wmscreen, wtext->core->window,
|
WMDrawString(wtext->core->screen_ptr->wmscreen, wtext->core->window,
|
||||||
wtext->invGC, wtext->font, x1, y2+TEXT_SHIFT, ptr, (ep - sp));
|
wtext->invGC, wtext->font, x1, y1, ptr, (ep - sp));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* And draw a quick little line for the cursor position */
|
/* And draw a quick little line for the cursor position */
|
||||||
|
|||||||
Reference in New Issue
Block a user