aboutsummaryrefslogtreecommitdiff
path: root/moc_x11.c
diff options
context:
space:
mode:
Diffstat (limited to 'moc_x11.c')
-rw-r--r--moc_x11.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/moc_x11.c b/moc_x11.c
index efc4ce3..76384aa 100644
--- a/moc_x11.c
+++ b/moc_x11.c
@@ -120,9 +120,11 @@ int main() {
int y_offset = 20;
int x = 10;
pthread_mutex_lock(&mh->lock);
+
+ XDrawString(dpy, win, DefaultGC(dpy, s), x, y_offset, moc_str_state(mh->state), strlen(moc_str_state(mh->state)));
+ y_offset += 15;
if(mh->state == PLAYING || mh->state == PAUSED) {
char *timestr= time_format(mh->time);
-
XDrawString(dpy, win, DefaultGC(dpy, s), x, y_offset, mh->title, strlen(mh->title));
y_offset += 15;
XDrawString(dpy, win, DefaultGC(dpy, s), x, y_offset, mh->artist, strlen(mh->artist));
@@ -132,7 +134,6 @@ int main() {
XDrawString(dpy, win, DefaultGC(dpy, s), x, y_offset, timestr, strlen(timestr));
y_offset += 15;
-
free(timestr);
}