diff options
author | fluxgen <fluxgen> | 2002-11-15 14:00:45 (GMT) |
---|---|---|
committer | fluxgen <fluxgen> | 2002-11-15 14:00:45 (GMT) |
commit | 0e53323c07e088800c105a8bb9be69eff417d47e (patch) | |
tree | b5f7c44c585e5d6c642a4790ed1c8af40984f932 /util | |
parent | 487ca76de988d98d168fdef057eb4b54bd234f29 (diff) | |
download | fluxbox_paul-0e53323c07e088800c105a8bb9be69eff417d47e.zip fluxbox_paul-0e53323c07e088800c105a8bb9be69eff417d47e.tar.bz2 |
fixed width
Diffstat (limited to 'util')
-rw-r--r-- | util/fbrun/main.cc | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/util/fbrun/main.cc b/util/fbrun/main.cc index 718c552..994ace8 100644 --- a/util/fbrun/main.cc +++ b/util/fbrun/main.cc | |||
@@ -19,7 +19,7 @@ | |||
19 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | 19 | // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER |
20 | // DEALINGS IN THE SOFTWARE. | 20 | // DEALINGS IN THE SOFTWARE. |
21 | 21 | ||
22 | // $Id: main.cc,v 1.4 2002/11/13 22:25:59 fluxgen Exp $ | 22 | // $Id: main.cc,v 1.5 2002/11/15 14:00:45 fluxgen Exp $ |
23 | 23 | ||
24 | #include "FbRun.hh" | 24 | #include "FbRun.hh" |
25 | #include "BaseDisplay.hh" | 25 | #include "BaseDisplay.hh" |
@@ -66,7 +66,7 @@ void showUsage(const char *progname) { | |||
66 | int main(int argc, char **argv) { | 66 | int main(int argc, char **argv) { |
67 | int x = 0, y = 0; // default pos of window | 67 | int x = 0, y = 0; // default pos of window |
68 | size_t width = 200, height = 32; // default size of window | 68 | size_t width = 200, height = 32; // default size of window |
69 | bool set_height = false; // use height of font by default | 69 | bool set_height = false, set_width=false; // use height/width of font by default |
70 | bool set_pos = false; // set position | 70 | bool set_pos = false; // set position |
71 | bool antialias = false; // antialias text | 71 | bool antialias = false; // antialias text |
72 | string fontname; // font name | 72 | string fontname; // font name |
@@ -86,6 +86,7 @@ int main(int argc, char **argv) { | |||
86 | text = argv[++i]; | 86 | text = argv[++i]; |
87 | } else if (strcmp(argv[i], "-w") == 0 && i+1 < argc) { | 87 | } else if (strcmp(argv[i], "-w") == 0 && i+1 < argc) { |
88 | width = atoi(argv[++i]); | 88 | width = atoi(argv[++i]); |
89 | set_width = true; | ||
89 | } else if (strcmp(argv[i], "-h") == 0 && i+1 < argc) { | 90 | } else if (strcmp(argv[i], "-h") == 0 && i+1 < argc) { |
90 | height = atoi(argv[++i]); | 91 | height = atoi(argv[++i]); |
91 | set_height = true; // mark true else the height of font will be used | 92 | set_height = true; // mark true else the height of font will be used |
@@ -150,7 +151,9 @@ int main(int argc, char **argv) { | |||
150 | fbrun.setBackground(xc_background); | 151 | fbrun.setBackground(xc_background); |
151 | 152 | ||
152 | if (set_height) | 153 | if (set_height) |
153 | fbrun.resize(width, height); | 154 | fbrun.resize(fbrun.width(), height); |
155 | if (set_width) | ||
156 | fbrun.resize(width, fbrun.height()); | ||
154 | if (antialias) | 157 | if (antialias) |
155 | fbrun.setAntialias(antialias); | 158 | fbrun.setAntialias(antialias); |
156 | // expand and load command history | 159 | // expand and load command history |