Another copy of my dotfiles. Because I don't completely trust GitHub.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
798 B

4 years ago
  1. --- dmenu.c
  2. +++ dmenu.c
  3. @@ -637,7 +637,8 @@ static void
  4. usage(void)
  5. {
  6. fputs("usage: dmenu [-bfiv] [-l lines] [-p prompt] [-fn font] [-m monitor]\n"
  7. - " [-nb color] [-nf color] [-sb color] [-sf color] [-w windowid]\n", stderr);
  8. + " [-nb color] [-nf color] [-sb color] [-sf color] [-w windowid]\n"
  9. + " [-it text]\n", stderr);
  10. exit(1);
  11. }
  12. @@ -680,7 +681,10 @@ main(int argc, char *argv[])
  13. colors[SchemeSel][ColFg] = argv[++i];
  14. else if (!strcmp(argv[i], "-w")) /* embedding window id */
  15. embed = argv[++i];
  16. - else
  17. + else if (!strcmp(argv[i], "-it")) { /* embedding window id */
  18. + const char * text = argv[++i];
  19. + insert(text, strlen(text));
  20. + } else
  21. usage();
  22. if (!setlocale(LC_CTYPE, "") || !XSupportsLocale())