Diffstat (limited to 'noncore/tools/calculator/calculatorimpl.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/tools/calculator/calculatorimpl.cpp | 73 |
1 files changed, 67 insertions, 6 deletions
diff --git a/noncore/tools/calculator/calculatorimpl.cpp b/noncore/tools/calculator/calculatorimpl.cpp index 3a6efe4..0925073 100644 --- a/noncore/tools/calculator/calculatorimpl.cpp +++ b/noncore/tools/calculator/calculatorimpl.cpp | |||
@@ -24,2 +24,3 @@ | |||
24 | */ | 24 | */ |
25 | // Sat 03-09-2002 L.J. Potter added the inlined pixmaps here | ||
25 | 26 | ||
@@ -41,2 +42,59 @@ | |||
41 | #include <math.h> | 42 | #include <math.h> |
43 | /* XPM */ | ||
44 | static char *oneoverx_xpm[] = { | ||
45 | /* width height num_colors chars_per_pixel */ | ||
46 | " 13 11 2 1", | ||
47 | /* colors */ | ||
48 | ". c None", | ||
49 | "# c #000000", | ||
50 | /* pixels */ | ||
51 | "......#......", | ||
52 | ".....##......", | ||
53 | "......#......" | ||
54 | ".....###.....", | ||
55 | ".............", | ||
56 | "..#########..", | ||
57 | ".............", | ||
58 | "....##.##....", | ||
59 | "......#......", | ||
60 | "......#......", | ||
61 | "....##.##....", | ||
62 | }; | ||
63 | /* XPM */ | ||
64 | static char *ythrootofx_xpm[] = { | ||
65 | /* width height num_colors chars_per_pixel */ | ||
66 | " 13 11 2 1", | ||
67 | /* colors */ | ||
68 | ". c None", | ||
69 | "# c #000000", | ||
70 | /* pixels */ | ||
71 | "#.#..........", | ||
72 | "#.#..........", | ||
73 | "###...#######", | ||
74 | "..#..#.......", | ||
75 | "###..#.......", | ||
76 | ".....#.#...#.", | ||
77 | ".#..#...#.#..", | ||
78 | "#.#.#....#...", | ||
79 | "..#.#...#.#..", | ||
80 | "...#...#...#.", | ||
81 | "...#........." | ||
82 | }; | ||
83 | /* XPM */ | ||
84 | static char *xtopowerofy_xpm[] = { | ||
85 | /* width height num_colors chars_per_pixel */ | ||
86 | " 9 8 2 1", | ||
87 | /* colors */ | ||
88 | ". c None", | ||
89 | "# c #000000", | ||
90 | /* pixels */ | ||
91 | "......#.#", | ||
92 | "......#.#", | ||
93 | "......###", | ||
94 | "#...#...#", | ||
95 | ".#.#..###", | ||
96 | "..#......", | ||
97 | ".#.#.....", | ||
98 | "#...#...." | ||
99 | }; | ||
42 | 100 | ||
@@ -46,5 +104,5 @@ CalculatorImpl::CalculatorImpl( QWidget * parent, const char * name, | |||
46 | { | 104 | { |
47 | xtopowerofy = Resource::loadPixmap("xtopowerofy"); | 105 | // xtopowerofy = Resource::loadPixmap("xtopowerofy"); |
48 | ythrootofx = Resource::loadPixmap("ythrootofx"); | 106 | // ythrootofx = Resource::loadPixmap("ythrootofx"); |
49 | oneoverx = Resource::loadPixmap("oneoverx"); | 107 | // oneoverx = Resource::loadPixmap("oneoverx"); |
50 | 108 | ||
@@ -291,10 +349,13 @@ void CalculatorImpl::function_button(int mode){ | |||
291 | void CalculatorImpl::display_pixmap_faces() { | 349 | void CalculatorImpl::display_pixmap_faces() { |
350 | QPixmap image0( ( const char** ) xtopowerofy_xpm); | ||
292 | QPushButton* tmpbutton = func_buttons[5]; | 351 | QPushButton* tmpbutton = func_buttons[5]; |
293 | tmpbutton->setPixmap(xtopowerofy); | 352 | tmpbutton->setPixmap(image0); |
294 | 353 | ||
354 | QPixmap image1( ( const char** ) ythrootofx_xpm); | ||
295 | tmpbutton = func_buttons[6]; | 355 | tmpbutton = func_buttons[6]; |
296 | tmpbutton->setPixmap(ythrootofx); | 356 | tmpbutton->setPixmap(image1); |
297 | 357 | ||
358 | QPixmap image2( ( const char** ) oneoverx_xpm); | ||
298 | tmpbutton = func_buttons[3]; | 359 | tmpbutton = func_buttons[3]; |
299 | tmpbutton->setPixmap(oneoverx); | 360 | tmpbutton->setPixmap(image2); |
300 | } | 361 | } |