diff --git a/samples/toolbar/Makefile.in b/samples/toolbar/Makefile.in index a5608b2664..41454ed5ff 100644 --- a/samples/toolbar/Makefile.in +++ b/samples/toolbar/Makefile.in @@ -155,7 +155,7 @@ toolbar$(EXEEXT): $(TOOLBAR_OBJECTS) $(__toolbar___win32rc) $(CXX) -o $@ $(TOOLBAR_OBJECTS) -L$(LIBDIRNAME) $(LDFLAGS_GUI) $(SAMPLES_RPATH_FLAG) $(LDFLAGS) $(WX_LDFLAGS) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_SCINTILLA_IF_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_p) $(EXTRALIBS_FOR_GUI) $(__LIB_ZLIB_p) $(__LIB_REGEX_p) $(__LIB_EXPAT_p) $(EXTRALIBS_FOR_BASE) $(LIBS) $(__toolbar___os2_emxbindcmd) -@COND_PLATFORM_MACOSX_1@toolbar.app/Contents/PkgInfo: toolbar$(EXEEXT) $(top_srcdir)/src/osx/carbon/Info.plist.in $(top_srcdir)/src/osx/carbon/wxmac.icns +@COND_PLATFORM_MACOSX_1@toolbar.app/Contents/PkgInfo: toolbar$(EXEEXT) $(top_srcdir)/src/osx/carbon/Info.plist.in $(top_srcdir)/src/osx/carbon/wxmac.icns $(srcdir)/bitmaps/new.png $(srcdir)/bitmaps/open.png $(srcdir)/bitmaps/save.png $(srcdir)/bitmaps/copy.png $(srcdir)/bitmaps/cut.png $(srcdir)/bitmaps/paste.png $(srcdir)/bitmaps/print.png $(srcdir)/bitmaps/help.png @COND_PLATFORM_MACOSX_1@ mkdir -p toolbar.app/Contents @COND_PLATFORM_MACOSX_1@ mkdir -p toolbar.app/Contents/MacOS @COND_PLATFORM_MACOSX_1@ mkdir -p toolbar.app/Contents/Resources @@ -179,6 +179,7 @@ toolbar$(EXEEXT): $(TOOLBAR_OBJECTS) $(__toolbar___win32rc) @COND_PLATFORM_MACOSX_1@ @COND_PLATFORM_MACOSX_1@ @COND_PLATFORM_MACOSX_1@ cp -f $(top_srcdir)/src/osx/carbon/wxmac.icns toolbar.app/Contents/Resources/wxmac.icns +@COND_PLATFORM_MACOSX_1@ cp -f $(srcdir)/bitmaps/new.png $(srcdir)/bitmaps/open.png $(srcdir)/bitmaps/save.png $(srcdir)/bitmaps/copy.png $(srcdir)/bitmaps/cut.png $(srcdir)/bitmaps/paste.png $(srcdir)/bitmaps/print.png $(srcdir)/bitmaps/help.png toolbar.app/Contents/Resources @COND_PLATFORM_MACOSX_1@toolbar_bundle: $(____toolbar_BUNDLE_TGT_REF_DEP) diff --git a/samples/toolbar/bitmaps/README.md b/samples/toolbar/bitmaps/README.md new file mode 100644 index 0000000000..e64df36c69 --- /dev/null +++ b/samples/toolbar/bitmaps/README.md @@ -0,0 +1,10 @@ +PNG icons in this directory are public domain were taken from Tango Desktop +Project[1] and are in public domain. + +[1]: http://tango.freedesktop.org/Tango_Desktop_Project + +The `foo_png.c` files were generated by running + + $ ../../../misc/scripts/png2c.py foo.png > foo_png.c + +for each icon. diff --git a/samples/toolbar/bitmaps/copy.bmp b/samples/toolbar/bitmaps/copy.bmp deleted file mode 100644 index a21608fc23..0000000000 Binary files a/samples/toolbar/bitmaps/copy.bmp and /dev/null differ diff --git a/samples/toolbar/bitmaps/copy.png b/samples/toolbar/bitmaps/copy.png new file mode 100644 index 0000000000..8dd48c4949 Binary files /dev/null and b/samples/toolbar/bitmaps/copy.png differ diff --git a/samples/toolbar/bitmaps/copy.xpm b/samples/toolbar/bitmaps/copy.xpm deleted file mode 100644 index 15eb885af9..0000000000 --- a/samples/toolbar/bitmaps/copy.xpm +++ /dev/null @@ -1,44 +0,0 @@ -/* XPM */ -static const char *const copy_xpm[] = { -/* columns rows colors chars-per-pixel */ -"16 15 23 1", -"+ c #769CDA", -": c #DCE6F6", -"X c #3365B7", -"* c #FFFFFF", -"o c #9AB6E4", -"< c #EAF0FA", -"# c #B1C7EB", -". c #6992D7", -"3 c #F7F9FD", -", c #F0F5FC", -"$ c #A8C0E8", -" c None", -"- c #FDFEFF", -"& c #C4D5F0", -"1 c #E2EAF8", -"O c #89A9DF", -"= c #D2DFF4", -"4 c #FAFCFE", -"2 c #F5F8FD", -"; c #DFE8F7", -"% c #B8CCEC", -"> c #E5EDF9", -"@ c #648FD6", -/* pixels */ -" .....XX ", -" .oO+@X#X ", -" .$oO+X##X ", -" .%$o........ ", -" .&%$.*=&#o.-. ", -" .=&%.*;=&#.--. ", -" .:=&.*>;=&.... ", -" .>:=.*,>;=&#o. ", -" .<1:.*2,>:=&#. ", -" .2<1.*32,>:=&. ", -" .32<.*432,>:=. ", -" .32<.*-432,>:. ", -" .....**-432,>. ", -" .***-432,. ", -" .......... " -}; diff --git a/samples/toolbar/bitmaps/copy_png.c b/samples/toolbar/bitmaps/copy_png.c new file mode 100644 index 0000000000..657a2ad8ff --- /dev/null +++ b/samples/toolbar/bitmaps/copy_png.c @@ -0,0 +1,65 @@ +/* copy.png - 498 bytes */ +static const unsigned char copy_png[] = { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, + 0x00, 0x00, 0x00, 0x0d, 0x49, 0x48, 0x44, 0x52, + 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, + 0x08, 0x06, 0x00, 0x00, 0x00, 0x1f, 0xf3, 0xff, + 0x61, 0x00, 0x00, 0x00, 0x06, 0x62, 0x4b, 0x47, + 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf9, + 0x43, 0xbb, 0x7f, 0x00, 0x00, 0x00, 0x09, 0x70, + 0x48, 0x59, 0x73, 0x00, 0x00, 0x0b, 0x13, 0x00, + 0x00, 0x0b, 0x13, 0x01, 0x00, 0x9a, 0x9c, 0x18, + 0x00, 0x00, 0x00, 0x07, 0x74, 0x49, 0x4d, 0x45, + 0x07, 0xd5, 0x0a, 0x1a, 0x14, 0x08, 0x2f, 0x83, + 0x14, 0x34, 0x9b, 0x00, 0x00, 0x01, 0x7f, 0x49, + 0x44, 0x41, 0x54, 0x38, 0xcb, 0x95, 0x93, 0x4b, + 0x4b, 0x02, 0x51, 0x18, 0x86, 0xdf, 0x23, 0x33, + 0x63, 0xda, 0x80, 0xfd, 0x0a, 0xcf, 0x08, 0xdd, + 0x16, 0xfd, 0x8f, 0x08, 0x5a, 0xb6, 0x88, 0xa0, + 0x75, 0x17, 0xf0, 0x42, 0xb6, 0xb0, 0x45, 0x91, + 0x76, 0xdb, 0x44, 0x44, 0x44, 0x1b, 0xb1, 0x36, + 0x05, 0xfe, 0x04, 0x31, 0xb3, 0x36, 0x81, 0x65, + 0x30, 0xa3, 0xbf, 0xa0, 0x9a, 0x30, 0x05, 0x37, + 0xcd, 0xed, 0xb4, 0x69, 0x74, 0x46, 0x47, 0xb1, + 0x6f, 0xf5, 0x9d, 0xc3, 0x79, 0x1f, 0xde, 0xf7, + 0xe3, 0x3b, 0xe4, 0xe8, 0x24, 0x33, 0xaf, 0xeb, + 0xfa, 0x2c, 0x46, 0x28, 0xc1, 0xcf, 0xbd, 0x6d, + 0xae, 0xc5, 0xef, 0x9c, 0x77, 0x9c, 0x61, 0x18, + 0xd3, 0xf1, 0xe8, 0xd6, 0x28, 0x7a, 0xa4, 0x0f, + 0xf6, 0x26, 0x01, 0xb8, 0x01, 0x76, 0xd3, 0x6a, + 0x35, 0xc1, 0x18, 0xeb, 0x13, 0x11, 0x42, 0x00, + 0x00, 0xa1, 0xd0, 0x84, 0x27, 0x94, 0x73, 0x1e, + 0x6a, 0xb5, 0x1a, 0x5e, 0xab, 0x95, 0x85, 0xc6, + 0x77, 0x63, 0x66, 0x90, 0x8b, 0xfd, 0xcc, 0x6e, + 0xca, 0xee, 0x79, 0x9e, 0xbf, 0x75, 0x01, 0x24, + 0x49, 0x42, 0xb1, 0x54, 0x98, 0xfa, 0x47, 0xa4, + 0x45, 0x17, 0x40, 0x51, 0x94, 0x4e, 0x8c, 0x56, + 0xab, 0x39, 0x54, 0x6c, 0x47, 0x72, 0x01, 0x28, + 0xa5, 0x28, 0x96, 0x0a, 0x9d, 0xb3, 0x2c, 0xcb, + 0x9e, 0xe2, 0x48, 0x24, 0xd2, 0x3f, 0x03, 0xc6, + 0x18, 0x64, 0x59, 0x76, 0x0d, 0xd2, 0xf9, 0x70, + 0x50, 0xb9, 0x00, 0x94, 0x52, 0x94, 0xca, 0xc5, + 0xa1, 0x0e, 0x7a, 0xa1, 0x9c, 0x2d, 0xb6, 0x2c, + 0x06, 0x45, 0x19, 0xcd, 0x41, 0x30, 0x38, 0x8e, + 0x76, 0xbb, 0xdd, 0x05, 0xe8, 0xba, 0x0e, 0xc6, + 0x18, 0xc2, 0x61, 0x8a, 0xf2, 0x53, 0x69, 0xa8, + 0x03, 0x4a, 0x25, 0x98, 0xa6, 0x81, 0xca, 0x4b, + 0xa5, 0x0b, 0xd0, 0xb4, 0x1f, 0x04, 0x02, 0x63, + 0xb0, 0x2c, 0x36, 0xd4, 0xee, 0xe5, 0xd5, 0x05, + 0x1e, 0x1e, 0xef, 0xdd, 0x11, 0x04, 0x9e, 0xaf, + 0x9e, 0x9d, 0x9f, 0xba, 0x16, 0x87, 0x31, 0xcb, + 0xd3, 0xb6, 0x28, 0x8a, 0x58, 0x59, 0x5e, 0x85, + 0x65, 0x99, 0x50, 0xbf, 0x54, 0xe4, 0xae, 0xb3, + 0xe0, 0x36, 0xd6, 0xa3, 0x79, 0x00, 0x79, 0xc7, + 0x72, 0x6c, 0x1b, 0x86, 0xe1, 0xeb, 0x15, 0x3b, + 0x4b, 0x55, 0x55, 0xe4, 0x6e, 0xb2, 0x00, 0xf0, + 0xec, 0xf3, 0x1a, 0x92, 0xa6, 0xe9, 0xf0, 0xfb, + 0xfd, 0x10, 0x04, 0x01, 0xa2, 0x28, 0x82, 0x10, + 0x82, 0x7a, 0xbd, 0x0e, 0x80, 0xe0, 0xe3, 0xf3, + 0xdd, 0x16, 0xa7, 0x12, 0xb1, 0xe4, 0x1c, 0xe9, + 0x15, 0x1f, 0x1e, 0xa7, 0xb3, 0xa6, 0x69, 0x2e, + 0x79, 0x7d, 0xac, 0xbf, 0x2a, 0x00, 0x28, 0x24, + 0x62, 0xc9, 0x1d, 0x00, 0xf8, 0x05, 0x42, 0x59, + 0xa6, 0x03, 0x15, 0x88, 0xf7, 0xd8, 0x00, 0x00, + 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, + 0x60, 0x82}; diff --git a/samples/toolbar/bitmaps/cut.bmp b/samples/toolbar/bitmaps/cut.bmp deleted file mode 100644 index d41668ab3f..0000000000 Binary files a/samples/toolbar/bitmaps/cut.bmp and /dev/null differ diff --git a/samples/toolbar/bitmaps/cut.png b/samples/toolbar/bitmaps/cut.png new file mode 100644 index 0000000000..dc9eb9a7ad Binary files /dev/null and b/samples/toolbar/bitmaps/cut.png differ diff --git a/samples/toolbar/bitmaps/cut.xpm b/samples/toolbar/bitmaps/cut.xpm deleted file mode 100644 index e638157f59..0000000000 --- a/samples/toolbar/bitmaps/cut.xpm +++ /dev/null @@ -1,46 +0,0 @@ -/* XPM */ -static const char *const cut_xpm[] = { -/* columns rows colors chars-per-pixel */ -"16 15 25 1", -"6 c #D8BDC0", -": c #C3C3C4", -"- c #FFFFFF", -". c #6C6D70", -"2 c #AD3A45", -"o c #DBDBDB", -"# c #939495", -"< c #E42234", -"& c #C3C5C8", -"; c #C6CCD3", -"% c #B7B7B8", -" c None", -"* c #DFE0E2", -"5 c #B69596", -"3 c #9C2A35", -"1 c #CFCFD0", -", c #AB5C64", -"+ c #D2D3D4", -"$ c #BCBDBE", -"@ c #C6C8CA", -"> c #CDC0C1", -"O c #826F72", -"X c #979BA0", -"4 c #9B8687", -"= c #9FA0A0", -/* pixels */ -" .X .o ", -" O.+ @. ", -" O. .. ", -" O#$ %.& ", -" O.*.. ", -" #%#.. ", -" O=-.. ", -" #%#;. ", -" OO:=O ", -" >,,<, ,<,,1 ", -" ><23<1 1<32<1 ", -" ,2 4< <5 2, ", -" <, ,2 2, ,< ", -" 23,<5 5<,32 ", -" 6225 522> " -}; diff --git a/samples/toolbar/bitmaps/cut_png.c b/samples/toolbar/bitmaps/cut_png.c new file mode 100644 index 0000000000..0ac463dc38 --- /dev/null +++ b/samples/toolbar/bitmaps/cut_png.c @@ -0,0 +1,103 @@ +/* cut.png - 807 bytes */ +static const unsigned char cut_png[] = { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, + 0x00, 0x00, 0x00, 0x0d, 0x49, 0x48, 0x44, 0x52, + 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, + 0x08, 0x06, 0x00, 0x00, 0x00, 0x1f, 0xf3, 0xff, + 0x61, 0x00, 0x00, 0x00, 0x06, 0x62, 0x4b, 0x47, + 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf9, + 0x43, 0xbb, 0x7f, 0x00, 0x00, 0x00, 0x09, 0x70, + 0x48, 0x59, 0x73, 0x00, 0x00, 0x0b, 0x13, 0x00, + 0x00, 0x0b, 0x13, 0x01, 0x00, 0x9a, 0x9c, 0x18, + 0x00, 0x00, 0x00, 0x07, 0x74, 0x49, 0x4d, 0x45, + 0x07, 0xd5, 0x0a, 0x1c, 0x16, 0x1d, 0x31, 0x68, + 0x41, 0x64, 0x5e, 0x00, 0x00, 0x02, 0xb4, 0x49, + 0x44, 0x41, 0x54, 0x38, 0xcb, 0x85, 0x93, 0x5d, + 0x48, 0x93, 0x51, 0x18, 0xc7, 0x9f, 0x73, 0xde, + 0x77, 0xaf, 0xaf, 0xdb, 0xd4, 0x7d, 0xa5, 0xdb, + 0x6c, 0xf8, 0x15, 0x68, 0x78, 0xd1, 0x55, 0x10, + 0x74, 0x61, 0x94, 0x49, 0x57, 0x45, 0xde, 0x64, + 0x22, 0x11, 0x68, 0x69, 0x96, 0x58, 0xa8, 0x69, + 0x81, 0x90, 0x04, 0x95, 0xa5, 0x7d, 0x81, 0x88, + 0x10, 0x94, 0x18, 0xe8, 0x10, 0xf4, 0x4a, 0x90, + 0x24, 0xba, 0x0c, 0x02, 0xb5, 0x30, 0x6d, 0x33, + 0x36, 0xf2, 0x63, 0xef, 0x36, 0x75, 0x9b, 0xee, + 0x75, 0x5f, 0xef, 0x76, 0xce, 0xdb, 0x4d, 0xce, + 0x61, 0x5a, 0xe7, 0xee, 0xfc, 0xff, 0x0f, 0x3f, + 0xfe, 0xcf, 0xf3, 0x9c, 0x83, 0x20, 0xe5, 0x3c, + 0xeb, 0x7d, 0x72, 0x0e, 0x00, 0xde, 0xf3, 0x3c, + 0xef, 0x6d, 0xba, 0x79, 0xbb, 0x74, 0x8f, 0xd7, + 0xcf, 0xb2, 0xec, 0xa5, 0x3b, 0xcd, 0xad, 0xba, + 0x54, 0x1d, 0xa7, 0x5e, 0x18, 0x86, 0x19, 0xbb, + 0xd5, 0xd8, 0xac, 0x8d, 0x46, 0xa3, 0xcb, 0x7d, + 0xfd, 0xaf, 0x3b, 0x53, 0x3d, 0x05, 0xab, 0xb8, + 0x70, 0xe6, 0x74, 0xb9, 0xe6, 0xc5, 0xab, 0x9e, + 0x4f, 0x07, 0x02, 0x08, 0x21, 0xfc, 0x4f, 0x87, + 0x1d, 0xd7, 0xd5, 0xd6, 0x57, 0x10, 0x42, 0x8e, + 0xed, 0xe8, 0x4f, 0x7b, 0x1e, 0x97, 0x99, 0x73, + 0xcd, 0xa6, 0xed, 0x90, 0x88, 0x28, 0xa5, 0x27, + 0x0e, 0x04, 0x60, 0x8c, 0x43, 0x4b, 0x4b, 0xbf, + 0x80, 0x4f, 0x4b, 0x43, 0xb1, 0x58, 0xac, 0x74, + 0x27, 0x05, 0xcb, 0xb2, 0x53, 0x85, 0x85, 0x85, + 0xe0, 0x71, 0x7b, 0x28, 0xa5, 0xd4, 0xf1, 0xaf, + 0x04, 0x15, 0x36, 0x9b, 0x0d, 0x56, 0x5d, 0x2b, + 0xa8, 0xae, 0xb6, 0xbe, 0x38, 0x91, 0x48, 0x9c, + 0xea, 0x79, 0xde, 0x3d, 0x50, 0x52, 0x52, 0xa2, + 0x40, 0x80, 0xc1, 0xe1, 0x74, 0x00, 0x00, 0x58, + 0x0f, 0x04, 0xdc, 0x6d, 0xbd, 0xf7, 0x19, 0x63, + 0xbc, 0xbc, 0xb8, 0x68, 0x07, 0x3e, 0x8d, 0x47, + 0x92, 0x24, 0x1d, 0xd7, 0xeb, 0xf4, 0xd7, 0x64, + 0x0a, 0xb0, 0xbe, 0xb1, 0x46, 0x01, 0x60, 0xa2, + 0xad, 0xa5, 0xe3, 0xe1, 0x81, 0x00, 0x00, 0x00, + 0x4a, 0x69, 0xe5, 0xc2, 0x8f, 0x05, 0x79, 0x6d, + 0xcd, 0x03, 0x8d, 0x37, 0x9a, 0x54, 0xf1, 0x44, + 0x1c, 0x89, 0x62, 0x10, 0xe6, 0xe6, 0xe6, 0x24, + 0x00, 0xe8, 0xda, 0x5b, 0xff, 0x17, 0xa0, 0xad, + 0xa5, 0x63, 0x1a, 0x63, 0x3c, 0x64, 0x5f, 0xb4, + 0xd1, 0x60, 0x70, 0x0b, 0x6b, 0x34, 0x1a, 0x10, + 0xdc, 0x82, 0x2c, 0xcb, 0xf2, 0xbb, 0xb6, 0x96, + 0x8e, 0xe9, 0xff, 0x02, 0xfe, 0xa4, 0x98, 0x9a, + 0x9d, 0x99, 0xc6, 0x4e, 0xa7, 0x03, 0xd2, 0x39, + 0x1e, 0x32, 0xdf, 0x0e, 0x46, 0x10, 0x42, 0x6f, + 0xf6, 0xab, 0x45, 0x7b, 0x85, 0x31, 0xa3, 0xb1, + 0x97, 0x50, 0x7a, 0x3d, 0xbe, 0xb9, 0xa9, 0x26, + 0xe5, 0x65, 0x32, 0x33, 0xf9, 0x11, 0x15, 0x18, + 0x73, 0x40, 0x20, 0x74, 0x0b, 0x21, 0x34, 0x50, + 0xe9, 0xf1, 0xb4, 0xef, 0x0b, 0x18, 0x33, 0x99, + 0x3a, 0xe3, 0x7e, 0xff, 0x83, 0xa3, 0x26, 0x13, + 0x24, 0x28, 0x45, 0xde, 0xad, 0x4d, 0xd9, 0x17, + 0xde, 0x1e, 0x66, 0x65, 0x54, 0x55, 0x90, 0x9d, + 0xc3, 0xf0, 0x1c, 0x47, 0x25, 0x59, 0x06, 0xe7, + 0xfa, 0x3a, 0x28, 0xb2, 0xb2, 0xae, 0x56, 0xba, + 0xdd, 0x43, 0xc9, 0x16, 0xc6, 0xcd, 0xe6, 0x1a, + 0xc9, 0xe7, 0xeb, 0x2a, 0x36, 0x1a, 0xe9, 0xc2, + 0xca, 0xca, 0x54, 0x30, 0x12, 0x96, 0x02, 0x41, + 0x11, 0xd7, 0xc4, 0x69, 0x4d, 0x94, 0x23, 0x3a, + 0x96, 0xc1, 0x34, 0x10, 0x12, 0x13, 0x8e, 0xd5, + 0xd5, 0x0f, 0x47, 0xf4, 0x7a, 0x12, 0xf3, 0xf9, + 0x06, 0xc7, 0xcd, 0xe6, 0xdd, 0x97, 0x3a, 0x6a, + 0x30, 0x08, 0xf3, 0x45, 0x45, 0x64, 0x84, 0x61, + 0xee, 0x03, 0x00, 0xcc, 0x58, 0x2c, 0x21, 0xab, + 0x52, 0x99, 0xd8, 0xf1, 0x47, 0x18, 0x86, 0x7c, + 0xc9, 0x35, 0x07, 0x01, 0x00, 0x86, 0x31, 0x6e, + 0xff, 0x96, 0x9f, 0x4f, 0x46, 0x0d, 0x06, 0x61, + 0x77, 0x88, 0xb1, 0x98, 0x5e, 0x92, 0x24, 0x52, + 0x45, 0xc8, 0xa3, 0x09, 0x95, 0xea, 0xa5, 0x82, + 0x65, 0x79, 0x84, 0xb1, 0x3d, 0x39, 0x69, 0x8e, + 0x9b, 0x51, 0xf3, 0xe9, 0xaa, 0xc9, 0x8c, 0x8c, + 0xbe, 0xcb, 0x94, 0x76, 0x83, 0x2c, 0x53, 0x20, + 0xc4, 0xb0, 0x0b, 0xe0, 0x38, 0x41, 0xad, 0x54, + 0x32, 0x5f, 0xf3, 0xf2, 0x62, 0x26, 0x9d, 0xae, + 0x69, 0x5e, 0x10, 0xbc, 0x8a, 0xcc, 0xcc, 0x2b, + 0xc9, 0x8f, 0xa4, 0xd5, 0x36, 0x7c, 0x77, 0xb9, + 0x36, 0x0e, 0x1f, 0x3a, 0xd4, 0x30, 0x6b, 0xb1, + 0xc4, 0x08, 0xa5, 0x18, 0x30, 0x0e, 0x00, 0x00, + 0x30, 0x00, 0x00, 0xd5, 0x5a, 0xad, 0xcf, 0xe5, + 0xf7, 0x9f, 0xf4, 0x4b, 0x12, 0x1b, 0x00, 0x90, + 0x39, 0xb5, 0xfa, 0xec, 0x45, 0x41, 0x48, 0xee, + 0xdc, 0x2a, 0x8a, 0xee, 0xea, 0xec, 0x6c, 0x8f, + 0x37, 0x10, 0xc8, 0xf1, 0x87, 0xc3, 0x1a, 0x5f, + 0x24, 0xe2, 0x53, 0xa8, 0x54, 0xe7, 0xad, 0xa2, + 0xe8, 0xfe, 0x0d, 0xa0, 0xf3, 0x3a, 0x07, 0xdc, + 0x34, 0xc1, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x49, + 0x45, 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82}; diff --git a/samples/toolbar/bitmaps/help.bmp b/samples/toolbar/bitmaps/help.bmp deleted file mode 100644 index d5636e9aa2..0000000000 Binary files a/samples/toolbar/bitmaps/help.bmp and /dev/null differ diff --git a/samples/toolbar/bitmaps/help.png b/samples/toolbar/bitmaps/help.png new file mode 100644 index 0000000000..f25fc3fbf1 Binary files /dev/null and b/samples/toolbar/bitmaps/help.png differ diff --git a/samples/toolbar/bitmaps/help.xpm b/samples/toolbar/bitmaps/help.xpm deleted file mode 100644 index eebb5b518d..0000000000 --- a/samples/toolbar/bitmaps/help.xpm +++ /dev/null @@ -1,71 +0,0 @@ -/* XPM */ -static const char *const help_xpm[] = { -/* columns rows colors chars-per-pixel */ -"16 15 50 1", -"j c #4E7FD0", -"8 c #EDF2FB", -", c #7198D9", -"e c #DCE6F6", -"y c #FFFFFF", -"5 c #95B2E3", -"$ c #9AB6E4", -"g c #EAF0FA", -"1 c #2D59A3", -"@ c #B1C7EB", -"> c #6992D7", -"a c #D9E4F5", -"r c #356AC1", -"6 c #9BB7E5", -"= c #F7F9FD", -"+ c #BED0EE", -"z c #F0F5FC", -"f c #ADC4E9", -"# c #A8C0E8", -"7 c #CBD9F1", -"u c #366BC2", -" c None", -"c c #FDFEFF", -"w c #274D8D", -"t c #C4D5F0", -"% c #7CA0DC", -"h c #E2EAF8", -"p c #487BCE", -"o c #4377CD", -"4 c #2A549A", -"< c #254A87", -"O c #CCDAF2", -"& c #89A9DF", -"9 c #2B559B", -"* c #D2DFF4", -". c #3366BB", -": c #2E5CA8", -"x c #FAFCFE", -"l c #F5F8FD", -"2 c #799EDB", -"d c #DFE8F7", -"; c #A6BFE8", -"3 c #638ED5", -"- c #5282D0", -"X c #2A5398", -"0 c #B8CCEC", -"s c #376EC9", -"q c #2D5AA5", -"i c #285092", -"k c #8CACE0", -/* pixels */ -" .......Xo ", -" .O+@#$%.&o ", -" .*O+@#$.=&- ", -" ;:::>#@#.==&: ", -" ,<1234<>@....: ", -"5 c #3366BB", -"$ c #2E5CA8", -"9 c #FAFCFE", -"4 c #F5F8FD", -"q c #638ED5", -"o c #5282D0", -"& c #B8CCEC", -"X c #376EC9", -"< c #ACE95B", -/* pixels */ -" .XoO+@#$. ", -" .%%&*=-O;: ", -" >>>>%&*=O,=o ", -" ><<>%%&*O,,=o ", -">>><<>>>%&OOo+@ ", -"><<<<<<>1%&*=-@ ", -"><<<<<<>21%&*=@ ", -">>><<>>>321%&*+ ", -" ><<>456321%&O ", -" >>>>7456321%o ", -" .,8974563210 ", -" .,,897456320 ", -" .,,,8974563q ", -" .,,,,897456w ", -" .,,,,,89745w ", -" ............ " -}; diff --git a/samples/toolbar/bitmaps/new_png.c b/samples/toolbar/bitmaps/new_png.c new file mode 100644 index 0000000000..202fa4f11a --- /dev/null +++ b/samples/toolbar/bitmaps/new_png.c @@ -0,0 +1,62 @@ +/* new.png - 477 bytes */ +static const unsigned char new_png[] = { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, + 0x00, 0x00, 0x00, 0x0d, 0x49, 0x48, 0x44, 0x52, + 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, + 0x08, 0x06, 0x00, 0x00, 0x00, 0x1f, 0xf3, 0xff, + 0x61, 0x00, 0x00, 0x00, 0x06, 0x62, 0x4b, 0x47, + 0x44, 0x00, 0xfc, 0x00, 0xe9, 0x00, 0x4f, 0x34, + 0xd7, 0xb1, 0x0d, 0x00, 0x00, 0x00, 0x09, 0x70, + 0x48, 0x59, 0x73, 0x00, 0x00, 0x0b, 0x13, 0x00, + 0x00, 0x0b, 0x13, 0x01, 0x00, 0x9a, 0x9c, 0x18, + 0x00, 0x00, 0x00, 0x07, 0x74, 0x49, 0x4d, 0x45, + 0x07, 0xd5, 0x02, 0x12, 0x0e, 0x26, 0x1c, 0xd3, + 0xb6, 0x19, 0x29, 0x00, 0x00, 0x01, 0x6a, 0x49, + 0x44, 0x41, 0x54, 0x38, 0xcb, 0xad, 0x90, 0x4f, + 0x4b, 0x5b, 0x51, 0x10, 0xc5, 0x7f, 0x73, 0xef, + 0x8d, 0x56, 0x24, 0x7d, 0x25, 0x82, 0xd0, 0xca, + 0x5b, 0x16, 0xdc, 0xd4, 0xee, 0x5c, 0x66, 0xa9, + 0x1b, 0xf3, 0x0d, 0xb2, 0x71, 0x59, 0xbf, 0x45, + 0xde, 0xb2, 0xdd, 0x77, 0x23, 0x04, 0xc4, 0x82, + 0xdf, 0xc0, 0x4d, 0x37, 0xdd, 0x2a, 0x85, 0x52, + 0x4a, 0xb2, 0x52, 0x4a, 0x49, 0x5a, 0x84, 0x10, + 0xff, 0x45, 0x62, 0x9b, 0xde, 0x77, 0xc7, 0x85, + 0x26, 0xc6, 0x18, 0x93, 0x54, 0x7a, 0x36, 0x33, + 0x0c, 0x73, 0xe6, 0x9c, 0x33, 0x52, 0x2e, 0x97, + 0xb7, 0x6b, 0xb5, 0x5a, 0x91, 0x11, 0x98, 0x9d, + 0xfd, 0xcb, 0xdc, 0x5c, 0x9b, 0x67, 0xd1, 0x6f, + 0xf2, 0xcb, 0x9f, 0xdf, 0xe5, 0xa2, 0x6f, 0x1f, + 0xe1, 0xcf, 0xbe, 0x64, 0xc3, 0x19, 0xa5, 0x52, + 0x49, 0xc7, 0xe1, 0xfc, 0x78, 0x53, 0x2f, 0x4f, + 0xdf, 0x68, 0xe7, 0xbc, 0xa0, 0x97, 0x27, 0x2b, + 0x9d, 0x8b, 0xc6, 0xe2, 0xae, 0xb6, 0xb2, 0xeb, + 0xda, 0x32, 0x33, 0xae, 0xab, 0xd2, 0x6c, 0x36, + 0x09, 0x21, 0x00, 0x20, 0x22, 0x3d, 0xf5, 0x8c, + 0xd9, 0x63, 0xda, 0x7e, 0x21, 0xe3, 0xbe, 0x22, + 0x66, 0x09, 0xeb, 0x4c, 0x26, 0xd8, 0xf6, 0x6a, + 0xc7, 0xb7, 0x5b, 0x53, 0xce, 0x57, 0x7b, 0x07, + 0x06, 0xc9, 0xdd, 0x6a, 0xe4, 0x08, 0x6b, 0xea, + 0x88, 0x79, 0x85, 0xb8, 0x02, 0x60, 0x31, 0x2a, + 0x46, 0xd3, 0x5f, 0x8b, 0xe0, 0x5e, 0xba, 0xfe, + 0xac, 0x83, 0xe4, 0xeb, 0x5e, 0x6f, 0x3a, 0x0b, + 0x4c, 0x81, 0x38, 0x10, 0x0b, 0x82, 0x00, 0x17, + 0x6e, 0x34, 0x59, 0x08, 0x3a, 0x4f, 0xd0, 0xe7, + 0xd8, 0x50, 0x45, 0xd3, 0x69, 0x40, 0xd0, 0xb4, + 0xa2, 0xde, 0x9b, 0x7a, 0xc6, 0xa6, 0x15, 0xf7, + 0xd0, 0xe7, 0xbb, 0x87, 0x02, 0xaf, 0xf1, 0xe1, + 0x27, 0xe0, 0xb1, 0x5a, 0x01, 0x14, 0xef, 0x5f, + 0xe8, 0xe9, 0x59, 0xeb, 0xd3, 0xcc, 0xfc, 0xf7, + 0x83, 0x91, 0x11, 0x44, 0x04, 0xe5, 0x29, 0x1d, + 0x5d, 0x43, 0x75, 0x81, 0x34, 0xfd, 0x01, 0x3c, + 0x61, 0x6b, 0xe7, 0xd0, 0x6c, 0x6c, 0x6c, 0xbf, + 0x05, 0x70, 0xa3, 0xc8, 0xb7, 0x35, 0x8b, 0xd7, + 0x3c, 0x22, 0x42, 0x14, 0x45, 0x34, 0x1a, 0x49, + 0x4f, 0xd4, 0x30, 0x21, 0xfa, 0x7f, 0xd3, 0x8f, + 0x7b, 0x11, 0x86, 0x39, 0x78, 0x88, 0x7c, 0xc7, + 0xc1, 0xb0, 0xa5, 0xc1, 0xd9, 0xb0, 0x1d, 0x33, + 0xa9, 0xdd, 0xb1, 0x11, 0x72, 0xb9, 0x1c, 0x8f, + 0x81, 0x8b, 0xe3, 0xf8, 0x43, 0x92, 0x24, 0xc5, + 0x7f, 0x21, 0xc5, 0x71, 0xfc, 0x9e, 0xff, 0x85, + 0x2b, 0xcc, 0x3d, 0x99, 0x60, 0x7b, 0xac, 0x14, + 0xc9, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, + 0x44, 0xae, 0x42, 0x60, 0x82}; diff --git a/samples/toolbar/bitmaps/open.bmp b/samples/toolbar/bitmaps/open.bmp deleted file mode 100644 index 35ad487487..0000000000 Binary files a/samples/toolbar/bitmaps/open.bmp and /dev/null differ diff --git a/samples/toolbar/bitmaps/open.png b/samples/toolbar/bitmaps/open.png new file mode 100644 index 0000000000..ab940462fd Binary files /dev/null and b/samples/toolbar/bitmaps/open.png differ diff --git a/samples/toolbar/bitmaps/open.xpm b/samples/toolbar/bitmaps/open.xpm deleted file mode 100644 index 787164750e..0000000000 --- a/samples/toolbar/bitmaps/open.xpm +++ /dev/null @@ -1,57 +0,0 @@ -/* XPM */ -static const char *const open_xpm[] = { -/* columns rows colors chars-per-pixel */ -"16 15 36 1", -", c #AAC1E8", -"1 c #9AEA53", -"q c #DCE6F6", -". c #295193", -"; c #A9D066", -"r c #C6D6F0", -"$ c #4A7CCE", -"9 c #779DDB", -"8 c #EAF0FA", -"O c #6E96D8", -"X c #214279", -"e c #BED0EE", -"6 c #85A7DF", -"5 c #F0F5FC", -"t c #ADC4E9", -": c #3161B1", -" c None", -"u c #274D8B", -"& c #BFDC9B", -"> c #9FB9E5", -"y c #5584D1", -"w c #3569BF", -"% c #3A70CA", -"+ c #305FAC", -"3 c #5D89D3", -"0 c #D2DFF4", -"@ c #CAE2AA", -"= c #B2D58C", -"2 c #FAFCFE", -"# c #638ED5", -"* c #CEDCF2", -"4 c #90AFE2", -"< c #B3C8EB", -"7 c #E5EDF9", -"- c #A2BCE6", -"o c #DFF0D0", -/* pixels */ -" ", -" .... ", -"XXXXX .oo. ", -"XOOOO+ .@o. ", -"XOOOO#$%.&*XXX ", -"XOOOOOOO.=*X-X ", -"XOXXXX...;*XXXX:", -"XOX>,<.11111*X2:", -"X3X4>,<.111*X5-:", -"XX#64>,,.1*X78: ", -"XXO964>,,.X0q7: ", -"Xw3O964>,,er0t: ", -"X%y3O964>, c #FEE3D7", -"O c #FFFFFF", -"o c #7B767D", -"% c #F79586", -"& c #CAE1F3", -"@ c #F08B62", -"# c #FCCBB8", -"- c #FDD8C9", -"4 c #FFF8F4", -"5 c #FFF5F0", -" c None", -"$ c #F8AA8F", -", c #EFF6FC", -"1 c #F7FBFD", -"2 c #FAFCFE", -"; c #DAEAF7", -": c #E9F3FA", -"6 c #FFFAF8", -". c #3C78A6", -"3 c #FFF1ED", -"X c #9B8687", -"+ c #FBBCA4", -"* c #B6D5EE", -"= c #F4F9FD", -/* pixels */ -" ...... ", -" .XoOOOOoo. ", -".+XOOOOOOX@. ", -".+XXXXXXXX@. ", -".#++$$%@..... ", -".##++$$%.&*.=. ", -".-##++$$.;&.==. ", -".--##++$.:;.... ", -".>--##++.,:;&*. ", -".<>--##+.1,:;&. ", -".<<>--##.21,:;. ", -".3<<>--#.O21=:. ", -".45<<>--....... ", -".6453<>----. ", -"............ " -}; diff --git a/samples/toolbar/bitmaps/preview_png.c b/samples/toolbar/bitmaps/preview_png.c new file mode 100644 index 0000000000..e69de29bb2 diff --git a/samples/toolbar/bitmaps/print.bmp b/samples/toolbar/bitmaps/print.bmp deleted file mode 100644 index 8758e136d8..0000000000 Binary files a/samples/toolbar/bitmaps/print.bmp and /dev/null differ diff --git a/samples/toolbar/bitmaps/print.png b/samples/toolbar/bitmaps/print.png new file mode 100644 index 0000000000..35c37bd73e Binary files /dev/null and b/samples/toolbar/bitmaps/print.png differ diff --git a/samples/toolbar/bitmaps/print.xpm b/samples/toolbar/bitmaps/print.xpm deleted file mode 100644 index 5ad9d26a1a..0000000000 --- a/samples/toolbar/bitmaps/print.xpm +++ /dev/null @@ -1,56 +0,0 @@ -/* XPM */ -static const char *const print_xpm[] = { -/* columns rows colors chars-per-pixel */ -"16 15 35 1", -"y c #EDF2FB", -"9 c #4E7FD0", -"> c #B9CDED", -"# c #3365B7", -"r c #FFFFFF", -"8 c #2C58A0", -"X c #779DDB", -"7 c #7FA2DD", -"t c #3263B4", -"q c #6E96D8", -"= c #6992D7", -"* c #D9E4F5", -"0 c #356AC1", -"& c #CBD9F1", -"; c #97B4E3", -"e c #3161B1", -" c None", -"1 c #B5C9EB", -", c #7CA0DC", -"4 c #487BCE", -"- c #4377CD", -". c #5584D1", -"6 c #3A70CA", -"2 c #305FAC", -"< c #5685D2", -"w c #4075CC", -"5 c #638ED5", -"3 c #3467BC", -"% c #2F5DA9", -"o c #ECF1FA", -": c #D6E1F4", -"@ c #376EC9", -"$ c #2D5AA5", -"+ c #A2BCE6", -"O c #CFDDF3", -/* pixels */ -" .XXXXXXXX ", -" .oooooooX ", -" .OOOOOOOX ", -" .+++++++X ", -" @@#$%%%%%$%@@ ", -"#&*=-=;:>,<#*&# ", -".11.2345.63#11. ", -"4;;;;;;;;;;;;;4 ", -"677588888889776 ", -"0qq60wwwwwweqq0 ", -"3553rrrrrrr$553 ", -"3< c #C0D1EE", -/* pixels */ -" .", -" XoOOOOOOOOO+X .", -" @oO#######O+@ .", -" @oOOOOOOOOO+@ .", -" @oO#######O+@ .", -" @oOOOOOOOOO+@ .", -" @@+++++++++@@ .", -" @@@@@@@@@@@@@ .", -" @@@$$$$$$$$@@ .", -" @@$%%%&*=-O$@ .", -" @@$%X;;*=-O$@ .", -" @@$%X;;:>,O$@ .", -" @@$%X;;<12O$@ .", -" @@$<<2OOOOO$@ .", -". .." -}; diff --git a/samples/toolbar/bitmaps/save_png.c b/samples/toolbar/bitmaps/save_png.c new file mode 100644 index 0000000000..5a7e791ebc --- /dev/null +++ b/samples/toolbar/bitmaps/save_png.c @@ -0,0 +1,116 @@ +/* save.png - 911 bytes */ +static const unsigned char save_png[] = { + 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, + 0x00, 0x00, 0x00, 0x0d, 0x49, 0x48, 0x44, 0x52, + 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, + 0x08, 0x06, 0x00, 0x00, 0x00, 0x1f, 0xf3, 0xff, + 0x61, 0x00, 0x00, 0x00, 0x06, 0x62, 0x4b, 0x47, + 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf9, + 0x43, 0xbb, 0x7f, 0x00, 0x00, 0x00, 0x09, 0x70, + 0x48, 0x59, 0x73, 0x00, 0x00, 0x0b, 0x13, 0x00, + 0x00, 0x0b, 0x13, 0x01, 0x00, 0x9a, 0x9c, 0x18, + 0x00, 0x00, 0x00, 0x07, 0x74, 0x49, 0x4d, 0x45, + 0x07, 0xd5, 0x0b, 0x0a, 0x0d, 0x37, 0x0f, 0x9e, + 0x2a, 0xd8, 0xbf, 0x00, 0x00, 0x00, 0x8c, 0x74, + 0x45, 0x58, 0x74, 0x43, 0x6f, 0x6d, 0x6d, 0x65, + 0x6e, 0x74, 0x00, 0x4d, 0x65, 0x6e, 0x75, 0x2d, + 0x73, 0x69, 0x7a, 0x65, 0x64, 0x20, 0x69, 0x63, + 0x6f, 0x6e, 0x0a, 0x3d, 0x3d, 0x3d, 0x3d, 0x3d, + 0x3d, 0x3d, 0x3d, 0x3d, 0x3d, 0x0a, 0x0a, 0x28, + 0x63, 0x29, 0x20, 0x32, 0x30, 0x30, 0x33, 0x20, + 0x4a, 0x61, 0x6b, 0x75, 0x62, 0x20, 0x27, 0x6a, + 0x69, 0x6d, 0x6d, 0x61, 0x63, 0x27, 0x20, 0x53, + 0x74, 0x65, 0x69, 0x6e, 0x65, 0x72, 0x2c, 0x20, + 0x0a, 0x68, 0x74, 0x74, 0x70, 0x3a, 0x2f, 0x2f, + 0x6a, 0x69, 0x6d, 0x6d, 0x61, 0x63, 0x2e, 0x6d, + 0x75, 0x73, 0x69, 0x63, 0x68, 0x61, 0x6c, 0x6c, + 0x2e, 0x63, 0x7a, 0x0a, 0x0a, 0x63, 0x72, 0x65, + 0x61, 0x74, 0x65, 0x64, 0x20, 0x77, 0x69, 0x74, + 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x47, 0x49, + 0x4d, 0x50, 0x2c, 0x0a, 0x68, 0x74, 0x74, 0x70, + 0x3a, 0x2f, 0x2f, 0x77, 0x77, 0x77, 0x2e, 0x67, + 0x69, 0x6d, 0x70, 0x2e, 0x6f, 0x72, 0x67, 0x67, + 0x8a, 0xc7, 0x47, 0x00, 0x00, 0x02, 0x84, 0x49, + 0x44, 0x41, 0x54, 0x38, 0xcb, 0x9d, 0x92, 0x4d, + 0x48, 0x54, 0x61, 0x14, 0x86, 0x9f, 0xb9, 0xdd, + 0xf1, 0xe6, 0xcf, 0xe4, 0x4c, 0xe0, 0xb5, 0x31, + 0xcd, 0x91, 0xb2, 0x51, 0x6c, 0x51, 0x51, 0x34, + 0x26, 0x14, 0xb8, 0xc8, 0x16, 0x45, 0x14, 0x2e, + 0x42, 0x28, 0x2c, 0x82, 0x8a, 0xa9, 0xc1, 0x56, + 0x2d, 0x2a, 0xca, 0x45, 0x11, 0x54, 0x10, 0x06, + 0x52, 0xb4, 0x28, 0x0a, 0x22, 0xb0, 0x28, 0x28, + 0x6a, 0x5b, 0xd0, 0x22, 0x89, 0x44, 0x8a, 0xa6, + 0x45, 0x99, 0x54, 0x6a, 0x86, 0xa4, 0xe8, 0xdc, + 0x9b, 0xce, 0xfd, 0xf9, 0x4e, 0x0b, 0x61, 0x6c, + 0xb2, 0x36, 0xbd, 0x9b, 0xf3, 0xc1, 0xe1, 0x3c, + 0x9c, 0xf7, 0x3d, 0x5f, 0xe0, 0xc8, 0xd9, 0xe3, + 0x27, 0x3f, 0x5b, 0x15, 0xda, 0xd8, 0xb8, 0x33, + 0x09, 0x54, 0x01, 0x5b, 0x81, 0x86, 0xa0, 0x26, + 0xd9, 0xd0, 0xc2, 0x9f, 0x3f, 0x16, 0x19, 0xce, + 0xcd, 0xbb, 0xe7, 0xcf, 0x9d, 0xe0, 0x1f, 0x0a, + 0x34, 0x77, 0x74, 0xed, 0x8d, 0xad, 0xac, 0x8f, + 0x55, 0x97, 0x9b, 0x83, 0xab, 0x6b, 0xca, 0x3a, + 0xaa, 0x23, 0x85, 0x6b, 0x6d, 0xcf, 0x27, 0xfd, + 0x2d, 0xc3, 0xeb, 0xde, 0xe7, 0xea, 0xc3, 0xd7, + 0x51, 0xe2, 0x91, 0x37, 0xcb, 0xba, 0x3b, 0xef, + 0x0c, 0xff, 0x15, 0x90, 0x3c, 0x7d, 0xbe, 0xdb, + 0x9d, 0x1a, 0x3b, 0xec, 0x89, 0xc6, 0xa8, 0x1f, + 0x66, 0xda, 0x28, 0x63, 0x81, 0x1e, 0xa4, 0xad, + 0x65, 0x23, 0xcb, 0x2b, 0x16, 0x73, 0xf9, 0xfe, + 0x0b, 0xfc, 0xa1, 0x3e, 0x62, 0x05, 0xe3, 0x7f, + 0x9b, 0xef, 0x24, 0x79, 0x2c, 0x25, 0x5f, 0x46, + 0x06, 0x44, 0x44, 0x64, 0xe0, 0x73, 0x5a, 0x7a, + 0xd3, 0x03, 0x92, 0xba, 0xf6, 0x44, 0x12, 0x07, + 0x2f, 0x48, 0xcf, 0xab, 0x2f, 0xd2, 0xf5, 0xf4, + 0xad, 0xb4, 0x9e, 0xba, 0x2e, 0xef, 0x06, 0x87, + 0xe5, 0x77, 0x59, 0x96, 0x25, 0xa9, 0x8e, 0xa4, + 0xe8, 0x86, 0xee, 0xb3, 0xb4, 0x3c, 0xc6, 0xc4, + 0xc4, 0x04, 0xe1, 0x92, 0x72, 0xb4, 0xc0, 0x24, + 0x85, 0xe2, 0x00, 0xd0, 0xf7, 0x71, 0x14, 0xb3, + 0x44, 0xe7, 0xfb, 0x78, 0x86, 0xf7, 0x03, 0x9f, + 0x58, 0xb2, 0xa8, 0x10, 0x02, 0x00, 0x42, 0x41, + 0x41, 0x01, 0x00, 0xba, 0xe7, 0x82, 0x28, 0xc1, + 0x57, 0x8a, 0xed, 0x27, 0x6e, 0xcc, 0xdb, 0xb1, + 0x77, 0x70, 0x02, 0xd7, 0xf3, 0xb9, 0xd8, 0xf3, + 0x92, 0x8b, 0x3d, 0x2f, 0x01, 0x78, 0x7c, 0x76, + 0x1f, 0xc8, 0x6c, 0x5f, 0x03, 0x50, 0xa2, 0x50, + 0xbe, 0xa2, 0xeb, 0x50, 0x23, 0x00, 0xed, 0xbb, + 0x77, 0xd2, 0x98, 0x58, 0xc7, 0xcc, 0x8c, 0x4d, + 0x34, 0xa4, 0xd1, 0x94, 0x58, 0xcf, 0xde, 0xd6, + 0xed, 0x00, 0xec, 0x69, 0x5e, 0x81, 0xf2, 0x15, + 0x22, 0x32, 0x07, 0x10, 0x11, 0x22, 0x91, 0x30, + 0x15, 0x65, 0x31, 0x2e, 0x1d, 0x58, 0xc7, 0xcd, + 0xbb, 0x0f, 0x88, 0xc7, 0xaa, 0xd0, 0x08, 0xa0, + 0x11, 0x20, 0x51, 0x5f, 0xcd, 0xad, 0x7b, 0x8f, + 0x68, 0xdb, 0x5c, 0xc3, 0x8e, 0xa6, 0xf5, 0x14, + 0x15, 0x17, 0xe5, 0x03, 0x00, 0x2c, 0xcb, 0xc2, + 0x34, 0x4d, 0xaa, 0xa3, 0xb5, 0x39, 0x48, 0xe3, + 0xaa, 0xe5, 0xd4, 0xc6, 0x2a, 0xb9, 0x7c, 0xfb, + 0x21, 0x6d, 0x9b, 0x6b, 0xd8, 0xb5, 0x29, 0x81, + 0x69, 0x9a, 0x38, 0x8e, 0x93, 0xb3, 0xa8, 0x03, + 0x28, 0xa5, 0xb0, 0x6d, 0x1b, 0x00, 0xd3, 0x34, + 0x31, 0x4d, 0x93, 0xee, 0xa3, 0x85, 0x1c, 0xbb, + 0xda, 0x43, 0xd6, 0xf5, 0xd9, 0xdf, 0x52, 0x4f, + 0xfb, 0xb6, 0x2d, 0x68, 0x9a, 0xc6, 0xd4, 0xd4, + 0x14, 0xb6, 0x6d, 0x13, 0x0a, 0x85, 0xe6, 0x00, + 0x86, 0x61, 0x50, 0x59, 0x59, 0x99, 0x17, 0xde, + 0x9a, 0x86, 0x0d, 0x3c, 0xbb, 0xb2, 0x01, 0x00, + 0xdb, 0xb6, 0x71, 0x1c, 0x87, 0xe9, 0xe9, 0xe9, + 0x79, 0x21, 0xeb, 0x00, 0xfd, 0xfd, 0xfd, 0xb8, + 0xae, 0x9b, 0xd7, 0xf0, 0x3c, 0x0f, 0x5d, 0xd7, + 0x73, 0xef, 0x3f, 0x15, 0x89, 0x44, 0xf2, 0x33, + 0xf0, 0x3c, 0x8f, 0x74, 0x3a, 0xcd, 0xc8, 0xc8, + 0x08, 0x99, 0x4c, 0x06, 0x11, 0x41, 0x44, 0x30, + 0x0c, 0x83, 0xa1, 0xa1, 0x21, 0x42, 0xa1, 0x50, + 0xae, 0x5a, 0x96, 0x85, 0x65, 0x59, 0xf9, 0x57, + 0x50, 0x4a, 0x51, 0x5c, 0x5c, 0x44, 0x30, 0x18, + 0xcc, 0x7d, 0x12, 0x00, 0xd7, 0x75, 0x11, 0x35, + 0x0b, 0x13, 0x35, 0x7b, 0x3e, 0xe5, 0xfb, 0xf9, + 0x16, 0xc2, 0xe1, 0x30, 0xa5, 0xa5, 0xa5, 0x44, + 0xa3, 0x51, 0x00, 0xb2, 0xd9, 0x2c, 0x40, 0x2e, + 0xed, 0x78, 0x5d, 0x1c, 0xa5, 0x14, 0xf1, 0xba, + 0x3a, 0x94, 0x52, 0x2c, 0x89, 0x46, 0x73, 0x96, + 0x03, 0xa9, 0x8e, 0xe4, 0x19, 0xe0, 0x34, 0xff, + 0xa7, 0xce, 0x5f, 0x93, 0x3b, 0x33, 0x4c, 0xd5, + 0x22, 0x62, 0x6d, 0x00, 0x00, 0x00, 0x00, 0x49, + 0x45, 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82}; diff --git a/samples/toolbar/toolbar.bkl b/samples/toolbar/toolbar.bkl index 1eddc53bc3..b69e4e144c 100644 --- a/samples/toolbar/toolbar.bkl +++ b/samples/toolbar/toolbar.bkl @@ -1,6 +1,14 @@ + + + $(SRCDIR)/bitmaps/new.png $(SRCDIR)/bitmaps/open.png $(SRCDIR)/bitmaps/save.png $(SRCDIR)/bitmaps/copy.png $(SRCDIR)/bitmaps/cut.png $(SRCDIR)/bitmaps/paste.png $(SRCDIR)/bitmaps/print.png $(SRCDIR)/bitmaps/help.png + + diff --git a/samples/toolbar/toolbar.cpp b/samples/toolbar/toolbar.cpp index cfad7bb099..d3dd1bdcf2 100644 --- a/samples/toolbar/toolbar.cpp +++ b/samples/toolbar/toolbar.cpp @@ -31,14 +31,6 @@ #include "wx/colordlg.h" #include "wx/srchctrl.h" -// define this to use XPMs everywhere (by default, BMPs are used under Win) -// BMPs use less space, but aren't compiled into the executable on other platforms -#if defined(__WINDOWS__) && wxUSE_WXDIB - #define USE_XPM_BITMAPS 0 -#else - #define USE_XPM_BITMAPS 1 -#endif - // If this is 1, the sample will test an extra toolbar identical to the // main one, but not managed by the frame. This can test subtle differences // in the way toolbars are handled, especially on Mac where there is one @@ -52,20 +44,21 @@ // resources // ---------------------------------------------------------------------------- +// Under Windows, PNG files are embedded as resources, see toolbar.rc, but +// elsewhere we embed them in the program itself. We could also load them +// during run-time. #ifndef wxHAS_IMAGES_IN_RESOURCES #include "../sample.xpm" -#endif -#if USE_XPM_BITMAPS - #include "bitmaps/new.xpm" - #include "bitmaps/open.xpm" - #include "bitmaps/save.xpm" - #include "bitmaps/copy.xpm" - #include "bitmaps/cut.xpm" - #include "bitmaps/preview.xpm" // paste XPM - #include "bitmaps/print.xpm" - #include "bitmaps/help.xpm" -#endif // USE_XPM_BITMAPS + #include "bitmaps/new_png.c" + #include "bitmaps/open_png.c" + #include "bitmaps/save_png.c" + #include "bitmaps/copy_png.c" + #include "bitmaps/cut_png.c" + #include "bitmaps/paste_png.c" + #include "bitmaps/print_png.c" + #include "bitmaps/help_png.c" +#endif // !wxHAS_IMAGES_IN_RESOURCES enum Positions { @@ -301,6 +294,10 @@ bool MyApp::OnInit() if ( !wxApp::OnInit() ) return false; + // Because we use PNG icons in the frame ctor, we need to register this + // image handler before creating the frame. + wxImage::AddHandler(new wxPNGHandler); + // Create the main frame window MyFrame* frame = new MyFrame((wxFrame *) NULL, wxID_ANY, "wxToolBar Sample", @@ -312,8 +309,6 @@ bool MyApp::OnInit() frame->SetStatusText("Hello, wxWidgets"); #endif - wxInitAllImageHandlers(); - return true; } @@ -382,13 +377,8 @@ void MyFrame::PopulateToolbar(wxToolBarBase* toolBar) wxBitmap toolBarBitmaps[Tool_Max]; -#if USE_XPM_BITMAPS #define INIT_TOOL_BMP(bmp) \ - toolBarBitmaps[Tool_##bmp] = wxBitmap(bmp##_xpm) -#else // !USE_XPM_BITMAPS - #define INIT_TOOL_BMP(bmp) \ - toolBarBitmaps[Tool_##bmp] = wxBITMAP(bmp) -#endif // USE_XPM_BITMAPS/!USE_XPM_BITMAPS + toolBarBitmaps[Tool_##bmp] = wxBITMAP_PNG(bmp) INIT_TOOL_BMP(new); INIT_TOOL_BMP(open); @@ -739,12 +729,12 @@ void MyFrame::OnToggleAnotherToolbar(wxCommandEvent& WXUNUSED(event)) m_tbar->SetMargins(4, 4); - m_tbar->AddRadioTool(IDM_TOOLBAR_OTHER_1, "First", wxBITMAP(new)); - m_tbar->AddRadioTool(IDM_TOOLBAR_OTHER_2, "Second", wxBITMAP(open)); - m_tbar->AddRadioTool(IDM_TOOLBAR_OTHER_3, "Third", wxBITMAP(save)); + m_tbar->AddRadioTool(IDM_TOOLBAR_OTHER_1, "First", wxBITMAP_PNG(new)); + m_tbar->AddRadioTool(IDM_TOOLBAR_OTHER_2, "Second", wxBITMAP_PNG(open)); + m_tbar->AddRadioTool(IDM_TOOLBAR_OTHER_3, "Third", wxBITMAP_PNG(save)); m_tbar->AddSeparator(); - m_tbar->AddTool(wxID_HELP, "Help", wxBITMAP(help)); - m_tbar->AddTool(IDM_TOOLBAR_OTHER_4, "Disabled", wxBITMAP(cut), wxBITMAP(paste)); + m_tbar->AddTool(wxID_HELP, "Help", wxBITMAP_PNG(help)); + m_tbar->AddTool(IDM_TOOLBAR_OTHER_4, "Disabled", wxBITMAP_PNG(cut), wxBITMAP_PNG(paste)); m_tbar->EnableTool(IDM_TOOLBAR_OTHER_4, false); m_tbar->Realize(); @@ -992,7 +982,7 @@ void MyFrame::OnInsertPrint(wxCommandEvent& WXUNUSED(event)) wxToolBarBase *tb = GetToolBar(); tb->InsertTool(0, wxID_PRINT, "New print", - wxBITMAP(print), wxNullBitmap, + wxBITMAP_PNG(print), wxNullBitmap, wxITEM_NORMAL, "Delete this tool", "This button was inserted into the toolbar"); diff --git a/samples/toolbar/toolbar.rc b/samples/toolbar/toolbar.rc index 3a4920cf6c..ebad369ee3 100644 --- a/samples/toolbar/toolbar.rc +++ b/samples/toolbar/toolbar.rc @@ -1,11 +1,10 @@ #include "../sample.rc" -new BITMAP "bitmaps/new.bmp" -open BITMAP "bitmaps/open.bmp" -save BITMAP "bitmaps/save.bmp" -copy BITMAP "bitmaps/copy.bmp" -cut BITMAP "bitmaps/cut.bmp" -paste BITMAP "bitmaps/paste.bmp" -print BITMAP "bitmaps/print.bmp" -help BITMAP "bitmaps/help.bmp" - +new RCDATA "bitmaps/new.png" +open RCDATA "bitmaps/open.png" +save RCDATA "bitmaps/save.png" +copy RCDATA "bitmaps/copy.png" +cut RCDATA "bitmaps/cut.png" +paste RCDATA "bitmaps/paste.png" +print RCDATA "bitmaps/print.png" +help RCDATA "bitmaps/help.png"