comparison tools/fontconv.c @ 1357:370c40e0847f

Remove useless -o option from fontconv.
author Matti Hamalainen <ccr@tnsp.org>
date Fri, 25 Aug 2017 00:16:52 +0300
parents acae5f8ebc67
children 5e5f75b45f8d
comparison
equal deleted inserted replaced
1350:dcb5c16ecdb9 1357:370c40e0847f
23 23
24 static const DMOptArg optList[] = 24 static const DMOptArg optList[] =
25 { 25 {
26 { 0, '?', "help", "Show this help", OPT_NONE }, 26 { 0, '?', "help", "Show this help", OPT_NONE },
27 { 1, 'v', "verbose", "Be more verbose", OPT_NONE }, 27 { 1, 'v', "verbose", "Be more verbose", OPT_NONE },
28 { 2, 'o', "output", "Set output filename", OPT_ARGREQ }, 28 { 2, 's', "size", "Set glyph dimensions (-s W:H) for image->font conversion", OPT_ARGREQ },
29 { 3, 's', "size", "Set glyph dimensions (-s W:H) for image->font conversion", OPT_ARGREQ }, 29 #ifdef DM_GFX_TTF_TEXT
30 #ifdef DM_GFX_TTF_TEXT 30 { 3, 'c', "color", "TTF font rendering color (def: 0xFFFFFF)", OPT_ARGREQ },
31 { 4, 'c', "color", "TTF font rendering color (def: 0xFFFFFF)", OPT_ARGREQ },
32 #endif 31 #endif
33 }; 32 };
34 33
35 const int optListN = sizeof(optList) / sizeof(optList[0]); 34 const int optListN = sizeof(optList) / sizeof(optList[0]);
36 35
56 case 1: 55 case 1:
57 dmVerbosity++; 56 dmVerbosity++;
58 break; 57 break;
59 58
60 case 2: 59 case 2:
61 optOutFilename = optArg;
62 break;
63
64 case 3:
65 { 60 {
66 int w, h; 61 int w, h;
67 if (sscanf(optArg, "%d:%d", &w, &h) != 2) 62 if (sscanf(optArg, "%d:%d", &w, &h) != 2)
68 { 63 {
69 dmErrorMsg("Invalid argument for -s option, '%s'.\n", 64 dmErrorMsg("Invalid argument for -s option, '%s'.\n",
81 optSplitWidth = w; 76 optSplitWidth = w;
82 optSplitHeight = h; 77 optSplitHeight = h;
83 } 78 }
84 break; 79 break;
85 80
86 case 4: 81 case 3:
87 { 82 {
88 unsigned int colR, colG, colB, colA = 100; 83 unsigned int colR, colG, colB, colA = 100;
89 if (optArg[0] == '#' || optArg[0] == '$') optArg++; 84 if (optArg[0] == '#' || optArg[0] == '$') optArg++;
90 else 85 else
91 if (optArg[0] == '0' && optArg[1] == 'x') optArg += 2; 86 if (optArg[0] == '0' && optArg[1] == 'x') optArg += 2;