Changeset 06d0c81 in mainline for uspace/app/terminal/main.c


Ignore:
Timestamp:
2020-11-19T22:38:17Z (3 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
20667af
Parents:
2e0a2e7
Message:

Window placement

Needed to recreate the current 'desktop' and keep CI tests working

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/terminal/main.c

    r2e0a2e7 r06d0c81  
    4343static void print_syntax(void)
    4444{
    45         printf("Syntax: %s [-d <display-spec>]\n", NAME);
     45        printf("Syntax: %s [<options>]\n", NAME);
     46        printf("\t-d <display-spec> Use the specified display\n");
     47        printf("\t-topleft]         Place window to the top-left corner of "
     48            "the screen\n");
    4649}
    4750
     
    5053        const char *display_spec = UI_DISPLAY_DEFAULT;
    5154        terminal_t *terminal = NULL;
     55        terminal_flags_t flags = 0;
    5256        errno_t rc;
    5357        int i;
     
    6468
    6569                        display_spec = argv[i++];
     70                } else if (str_cmp(argv[i], "-topleft") == 0) {
     71                        ++i;
     72                        flags |= tf_topleft;
    6673                } else {
    6774                        printf("Invalid option '%s'.\n", argv[i]);
     
    7683        }
    7784
    78         rc = terminal_create(display_spec, 640, 480, &terminal);
     85        rc = terminal_create(display_spec, 640, 480, flags, &terminal);
    7986        if (rc != EOK)
    8087                return 1;
Note: See TracChangeset for help on using the changeset viewer.