diff options
author | Phil Jones <philj56@gmail.com> | 2021-10-31 22:16:40 +0000 |
---|---|---|
committer | Phil Jones <philj56@gmail.com> | 2021-10-31 23:12:07 +0000 |
commit | 6f199dc746bd377223e9bec60467c9060d1048ff (patch) | |
tree | acce570009d48e3efa6a1232c37070c1e0f456c8 /src/entry.c | |
parent | 7297ac5d9cac676ed6cd4552a6b47204f9db2512 (diff) |
Add actual greetd functionality.
Useable, but very barebones — not even any error message reporting.
Diffstat (limited to 'src/entry.c')
-rw-r--r-- | src/entry.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/entry.c b/src/entry.c index 7c34acf..63b6f87 100644 --- a/src/entry.c +++ b/src/entry.c @@ -133,15 +133,12 @@ void entry_update(struct entry *entry) /* Draw our text with Pango. */ color = entry->foreground_color; cairo_set_source_rgba(cr, color.r, color.g, color.b, color.a); - //const wchar_t *src = entry->password; - //wcsrtombs(entry->password_mb, &src, N_ELEM(entry->password_mb), NULL); size_t len = 0; for (unsigned int i = 0; i < entry->password_length; i++) { - len += wcrtomb(entry->password_mb + len, entry->password_character, NULL); + len += wcrtomb(entry->password_mb_print + len, entry->password_character, NULL); } - entry->password_mb[len] = '\0'; - fprintf(stderr, "%s\n", entry->password_mb); - pango_layout_set_text(layout, entry->password_mb, -1); + entry->password_mb_print[len] = '\0'; + pango_layout_set_text(layout, entry->password_mb_print, -1); pango_cairo_update_layout(cr, layout); pango_cairo_show_layout(cr, layout); |