From c0e46c32d792391156c62358f3d92e630ffcd9ed Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Mon, 14 Dec 2009 02:18:24 +0000 Subject: [PATCH] where-vessels: Tidy up ship size icon displays --- yarrg/icons.ceb/ct.xbm | 5 - yarrg/icons.ceb/dh.xbm | 5 - yarrg/icons.ceb/gf.xbm | 5 - yarrg/icons.ceb/ls.xbm | 5 - yarrg/icons.ceb/mb.xbm | 5 - yarrg/icons.ceb/mg.xbm | 5 - yarrg/icons.ceb/sl.xbm | 5 - yarrg/icons.ceb/wb.xbm | 5 - yarrg/icons.ceb/wf.xbm | 5 - yarrg/icons.ceb/xe.xbm | 5 - yarrg/icons.iwj/bg.xbm | 5 - yarrg/icons.iwj/ct.xbm | 5 - yarrg/icons.iwj/dh.xbm | 5 - yarrg/icons.iwj/gf.xbm | 5 - yarrg/icons.iwj/ls.xbm | 5 - yarrg/icons.iwj/mb.xbm | 5 - yarrg/icons.iwj/sl.xbm | 5 - yarrg/icons.iwj/wb.xbm | 5 - yarrg/icons.iwj/wf.xbm | 5 - yarrg/icons.iwj/xe.xbm | 5 - yarrg/{iconsdir => icons}/battle.xbm | 2 +- yarrg/{icons.ceb => icons}/bg.xbm | 0 yarrg/{iconsdir => icons}/ct.xbm | 0 yarrg/{iconsdir => icons}/dh.xbm | 0 yarrg/{iconsdir => icons}/gf.xbm | 0 yarrg/{iconsdir => icons}/locked.xbm | 0 yarrg/{iconsdir => icons}/ls.xbm | 0 yarrg/{iconsdir => icons}/mb.xbm | 0 yarrg/{icons.iwj => icons}/mg.xbm | 0 yarrg/icons/ours.xbm | 4 + yarrg/icons/query.xbm | 4 + yarrg/{iconsdir => icons}/sl.xbm | 0 yarrg/{iconsdir => icons}/unlocked.xbm | 2 +- yarrg/{iconsdir => icons}/wb.xbm | 0 yarrg/{iconsdir => icons}/wf.xbm | 0 yarrg/{iconsdir => icons}/xe.xbm | 0 yarrg/iconsdir/backup/ct.xbm | 5 - yarrg/iconsdir/backup/ls.xbm | 5 - yarrg/iconsdir/backup/mb.xbm | 5 - yarrg/iconsdir/backup/mg.xbm | 5 - yarrg/iconsdir/bg.xbm | 5 - yarrg/iconsdir/mg.xbm | 5 - yarrg/where-vessels | 131 ++++++++++++------------- 43 files changed, 72 insertions(+), 201 deletions(-) delete mode 100644 yarrg/icons.ceb/ct.xbm delete mode 100644 yarrg/icons.ceb/dh.xbm delete mode 100644 yarrg/icons.ceb/gf.xbm delete mode 100644 yarrg/icons.ceb/ls.xbm delete mode 100644 yarrg/icons.ceb/mb.xbm delete mode 100644 yarrg/icons.ceb/mg.xbm delete mode 100644 yarrg/icons.ceb/sl.xbm delete mode 100644 yarrg/icons.ceb/wb.xbm delete mode 100644 yarrg/icons.ceb/wf.xbm delete mode 100644 yarrg/icons.ceb/xe.xbm delete mode 100644 yarrg/icons.iwj/bg.xbm delete mode 100644 yarrg/icons.iwj/ct.xbm delete mode 100644 yarrg/icons.iwj/dh.xbm delete mode 100644 yarrg/icons.iwj/gf.xbm delete mode 100644 yarrg/icons.iwj/ls.xbm delete mode 100644 yarrg/icons.iwj/mb.xbm delete mode 100644 yarrg/icons.iwj/sl.xbm delete mode 100644 yarrg/icons.iwj/wb.xbm delete mode 100644 yarrg/icons.iwj/wf.xbm delete mode 100644 yarrg/icons.iwj/xe.xbm rename yarrg/{iconsdir => icons}/battle.xbm (59%) rename yarrg/{icons.ceb => icons}/bg.xbm (100%) rename yarrg/{iconsdir => icons}/ct.xbm (100%) rename yarrg/{iconsdir => icons}/dh.xbm (100%) rename yarrg/{iconsdir => icons}/gf.xbm (100%) rename yarrg/{iconsdir => icons}/locked.xbm (100%) rename yarrg/{iconsdir => icons}/ls.xbm (100%) rename yarrg/{iconsdir => icons}/mb.xbm (100%) rename yarrg/{icons.iwj => icons}/mg.xbm (100%) create mode 100644 yarrg/icons/ours.xbm create mode 100644 yarrg/icons/query.xbm rename yarrg/{iconsdir => icons}/sl.xbm (100%) rename yarrg/{iconsdir => icons}/unlocked.xbm (61%) rename yarrg/{iconsdir => icons}/wb.xbm (100%) rename yarrg/{iconsdir => icons}/wf.xbm (100%) rename yarrg/{iconsdir => icons}/xe.xbm (100%) delete mode 100644 yarrg/iconsdir/backup/ct.xbm delete mode 100644 yarrg/iconsdir/backup/ls.xbm delete mode 100644 yarrg/iconsdir/backup/mb.xbm delete mode 100644 yarrg/iconsdir/backup/mg.xbm delete mode 100644 yarrg/iconsdir/bg.xbm delete mode 100644 yarrg/iconsdir/mg.xbm diff --git a/yarrg/icons.ceb/ct.xbm b/yarrg/icons.ceb/ct.xbm deleted file mode 100644 index 94f926a..0000000 --- a/yarrg/icons.ceb/ct.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define ct_width 12 -#define ct_height 10 -static unsigned char ct_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x03, 0x00, 0x05, 0x00, 0x09, - 0xe0, 0x09, 0x20, 0x09, 0x20, 0x05, 0xe0, 0x03 }; diff --git a/yarrg/icons.ceb/dh.xbm b/yarrg/icons.ceb/dh.xbm deleted file mode 100644 index 1536867..0000000 --- a/yarrg/icons.ceb/dh.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define dh_width 12 -#define dh_height 10 -static unsigned char dh_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x18, 0x00, 0x28, 0x00, - 0x48, 0x00, 0x88, 0x00, 0x08, 0x01, 0xf8, 0x03 }; diff --git a/yarrg/icons.ceb/gf.xbm b/yarrg/icons.ceb/gf.xbm deleted file mode 100644 index a3d1f64..0000000 --- a/yarrg/icons.ceb/gf.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define gf_width 12 -#define gf_height 10 -static unsigned char gf_bits[] = { - 0x00, 0x00, 0x10, 0x00, 0x92, 0x00, 0x92, 0x00, 0x92, 0x00, 0x92, 0x04, - 0x92, 0x04, 0x92, 0x04, 0x92, 0x04, 0xff, 0x0f }; diff --git a/yarrg/icons.ceb/ls.xbm b/yarrg/icons.ceb/ls.xbm deleted file mode 100644 index 2b48fe4..0000000 --- a/yarrg/icons.ceb/ls.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define lg_width 12 -#define lg_height 10 -static unsigned char lg_bits[] = { - 0xfe, 0x03, 0x54, 0x05, 0xa8, 0x0a, 0xa8, 0x0a, 0xa8, 0x0a, 0xa8, 0x0a, - 0xa8, 0x0a, 0xa8, 0x0a, 0x54, 0x05, 0xfe, 0x03 }; diff --git a/yarrg/icons.ceb/mb.xbm b/yarrg/icons.ceb/mb.xbm deleted file mode 100644 index 4f21353..0000000 --- a/yarrg/icons.ceb/mb.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define mb_width 12 -#define mb_height 10 -static unsigned char mb_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0x20, 0x01, 0x60, 0x03, 0xa0, 0x05, 0x20, 0x09, - 0x3c, 0x09, 0x24, 0x09, 0xa4, 0x05, 0x7c, 0x03 }; diff --git a/yarrg/icons.ceb/mg.xbm b/yarrg/icons.ceb/mg.xbm deleted file mode 100644 index 9238d43..0000000 --- a/yarrg/icons.ceb/mg.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define mf_width 12 -#define mf_height 10 -static unsigned char mf_bits[] = { - 0x20, 0x00, 0x60, 0x00, 0xa4, 0x02, 0x2c, 0x05, 0x34, 0x09, 0x24, 0x09, - 0x24, 0x09, 0x27, 0x09, 0xb5, 0x0d, 0x6f, 0x07 }; diff --git a/yarrg/icons.ceb/sl.xbm b/yarrg/icons.ceb/sl.xbm deleted file mode 100644 index d08f9cb..0000000 --- a/yarrg/icons.ceb/sl.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define sl_width 12 -#define sl_height 10 -static unsigned char sl_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x20, 0x00, 0x20, 0x00, - 0x20, 0x00, 0x20, 0x00, 0x20, 0x00, 0xff, 0x0f }; diff --git a/yarrg/icons.ceb/wb.xbm b/yarrg/icons.ceb/wb.xbm deleted file mode 100644 index 11ddb0e..0000000 --- a/yarrg/icons.ceb/wb.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define wb_width 12 -#define wb_height 10 -static unsigned char wb_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0x08, 0x01, 0x08, 0x01, 0x08, 0x01, 0x08, 0x01, - 0x08, 0x01, 0x08, 0x01, 0x08, 0x01, 0xff, 0x0f }; diff --git a/yarrg/icons.ceb/wf.xbm b/yarrg/icons.ceb/wf.xbm deleted file mode 100644 index 4eadf62..0000000 --- a/yarrg/icons.ceb/wf.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define wf_width 12 -#define wf_height 10 -static unsigned char wf_bits[] = { - 0x00, 0x00, 0x20, 0x00, 0x22, 0x02, 0x22, 0x02, 0x22, 0x02, 0x22, 0x02, - 0x22, 0x02, 0x22, 0x02, 0x22, 0x02, 0xff, 0x0f }; diff --git a/yarrg/icons.ceb/xe.xbm b/yarrg/icons.ceb/xe.xbm deleted file mode 100644 index 1359144..0000000 --- a/yarrg/icons.ceb/xe.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define xe_width 12 -#define xe_height 10 -static unsigned char xe_bits[] = { - 0x44, 0x00, 0xcc, 0x00, 0x54, 0x01, 0x64, 0x02, 0x45, 0x04, 0x87, 0x0f, - 0x05, 0x01, 0x09, 0x02, 0xf1, 0x07, 0x3f, 0x00 }; diff --git a/yarrg/icons.iwj/bg.xbm b/yarrg/icons.iwj/bg.xbm deleted file mode 100644 index 583f3a1..0000000 --- a/yarrg/icons.iwj/bg.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define bg_width 12 -#define bg_height 10 -static unsigned char bg_bits[] = { - 0x10, 0x00, 0x30, 0x00, 0x50, 0x00, 0x92, 0x00, 0x16, 0x01, 0x1a, 0x02, - 0x12, 0x04, 0xe2, 0x0f, 0x42, 0x00, 0xfe, 0x00 }; diff --git a/yarrg/icons.iwj/ct.xbm b/yarrg/icons.iwj/ct.xbm deleted file mode 100644 index 94f926a..0000000 --- a/yarrg/icons.iwj/ct.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define ct_width 12 -#define ct_height 10 -static unsigned char ct_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x03, 0x00, 0x05, 0x00, 0x09, - 0xe0, 0x09, 0x20, 0x09, 0x20, 0x05, 0xe0, 0x03 }; diff --git a/yarrg/icons.iwj/dh.xbm b/yarrg/icons.iwj/dh.xbm deleted file mode 100644 index 1536867..0000000 --- a/yarrg/icons.iwj/dh.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define dh_width 12 -#define dh_height 10 -static unsigned char dh_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x18, 0x00, 0x28, 0x00, - 0x48, 0x00, 0x88, 0x00, 0x08, 0x01, 0xf8, 0x03 }; diff --git a/yarrg/icons.iwj/gf.xbm b/yarrg/icons.iwj/gf.xbm deleted file mode 100644 index a3d1f64..0000000 --- a/yarrg/icons.iwj/gf.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define gf_width 12 -#define gf_height 10 -static unsigned char gf_bits[] = { - 0x00, 0x00, 0x10, 0x00, 0x92, 0x00, 0x92, 0x00, 0x92, 0x00, 0x92, 0x04, - 0x92, 0x04, 0x92, 0x04, 0x92, 0x04, 0xff, 0x0f }; diff --git a/yarrg/icons.iwj/ls.xbm b/yarrg/icons.iwj/ls.xbm deleted file mode 100644 index 2b48fe4..0000000 --- a/yarrg/icons.iwj/ls.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define lg_width 12 -#define lg_height 10 -static unsigned char lg_bits[] = { - 0xfe, 0x03, 0x54, 0x05, 0xa8, 0x0a, 0xa8, 0x0a, 0xa8, 0x0a, 0xa8, 0x0a, - 0xa8, 0x0a, 0xa8, 0x0a, 0x54, 0x05, 0xfe, 0x03 }; diff --git a/yarrg/icons.iwj/mb.xbm b/yarrg/icons.iwj/mb.xbm deleted file mode 100644 index fdc07cf..0000000 --- a/yarrg/icons.iwj/mb.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define mb_width 12 -#define mb_height 10 -static unsigned char mb_bits[] = { - 0x00, 0x00, 0x90, 0x00, 0xb0, 0x01, 0xd0, 0x02, 0x98, 0x04, 0x94, 0x04, - 0xd2, 0x02, 0xbe, 0x01, 0x90, 0x00, 0xfe, 0x07}; diff --git a/yarrg/icons.iwj/sl.xbm b/yarrg/icons.iwj/sl.xbm deleted file mode 100644 index 2c7a4f2..0000000 --- a/yarrg/icons.iwj/sl.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define sl_width 12 -#define sl_height 10 -static unsigned char sl_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x10, 0x01, 0x10, 0x01, 0x10, 0x01, - 0x10, 0x01, 0xf0, 0x01, 0x40, 0x00, 0xf8, 0x03}; diff --git a/yarrg/icons.iwj/wb.xbm b/yarrg/icons.iwj/wb.xbm deleted file mode 100644 index 8de4857..0000000 --- a/yarrg/icons.iwj/wb.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define wb_width 12 -#define wb_height 10 -static unsigned char wb_bits[] = { - 0x00, 0x00, 0xfc, 0x03, 0x24, 0x02, 0x24, 0x02, 0x24, 0x02, 0x24, 0x02, - 0x24, 0x02, 0xfc, 0x03, 0x90, 0x00, 0xfe, 0x07}; diff --git a/yarrg/icons.iwj/wf.xbm b/yarrg/icons.iwj/wf.xbm deleted file mode 100644 index 69b6ba1..0000000 --- a/yarrg/icons.iwj/wf.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define wf_width 12 -#define wf_height 10 -static unsigned char wf_bits[] = { - 0xf8, 0x00, 0xce, 0x07, 0x4a, 0x04, 0x4a, 0x04, 0x4a, 0x04, 0x4a, 0x04, - 0x4a, 0x04, 0xfe, 0x07, 0x28, 0x01, 0xff, 0x0f}; diff --git a/yarrg/icons.iwj/xe.xbm b/yarrg/icons.iwj/xe.xbm deleted file mode 100644 index d3f5f32..0000000 --- a/yarrg/icons.iwj/xe.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define xe_width 12 -#define xe_height 10 -static unsigned char xe_bits[] = { - 0x00, 0x00, 0x48, 0x00, 0x5a, 0x00, 0xee, 0x00, 0x4a, 0x01, 0x4a, 0x02, - 0x4a, 0x04, 0xfe, 0x0f, 0x24, 0x01, 0xff, 0x0f}; diff --git a/yarrg/iconsdir/battle.xbm b/yarrg/icons/battle.xbm similarity index 59% rename from yarrg/iconsdir/battle.xbm rename to yarrg/icons/battle.xbm index 34a70ee..c9b20cc 100644 --- a/yarrg/iconsdir/battle.xbm +++ b/yarrg/icons/battle.xbm @@ -1,4 +1,4 @@ #define battle_width 5 #define battle_height 9 static unsigned char battle_bits[] = { - 0x0e, 0x0e, 0x0e, 0x04, 0x11, 0x0a, 0x04, 0x0a, 0x11}; + 0x0e, 0x0a, 0x0e, 0x04, 0x11, 0x0a, 0x04, 0x0a, 0x11}; diff --git a/yarrg/icons.ceb/bg.xbm b/yarrg/icons/bg.xbm similarity index 100% rename from yarrg/icons.ceb/bg.xbm rename to yarrg/icons/bg.xbm diff --git a/yarrg/iconsdir/ct.xbm b/yarrg/icons/ct.xbm similarity index 100% rename from yarrg/iconsdir/ct.xbm rename to yarrg/icons/ct.xbm diff --git a/yarrg/iconsdir/dh.xbm b/yarrg/icons/dh.xbm similarity index 100% rename from yarrg/iconsdir/dh.xbm rename to yarrg/icons/dh.xbm diff --git a/yarrg/iconsdir/gf.xbm b/yarrg/icons/gf.xbm similarity index 100% rename from yarrg/iconsdir/gf.xbm rename to yarrg/icons/gf.xbm diff --git a/yarrg/iconsdir/locked.xbm b/yarrg/icons/locked.xbm similarity index 100% rename from yarrg/iconsdir/locked.xbm rename to yarrg/icons/locked.xbm diff --git a/yarrg/iconsdir/ls.xbm b/yarrg/icons/ls.xbm similarity index 100% rename from yarrg/iconsdir/ls.xbm rename to yarrg/icons/ls.xbm diff --git a/yarrg/iconsdir/mb.xbm b/yarrg/icons/mb.xbm similarity index 100% rename from yarrg/iconsdir/mb.xbm rename to yarrg/icons/mb.xbm diff --git a/yarrg/icons.iwj/mg.xbm b/yarrg/icons/mg.xbm similarity index 100% rename from yarrg/icons.iwj/mg.xbm rename to yarrg/icons/mg.xbm diff --git a/yarrg/icons/ours.xbm b/yarrg/icons/ours.xbm new file mode 100644 index 0000000..6471fca --- /dev/null +++ b/yarrg/icons/ours.xbm @@ -0,0 +1,4 @@ +#define ours_width 5 +#define ours_height 9 +static unsigned char ours_bits[] = { + 0x07, 0x04, 0x07, 0x04, 0x04, 0x0e, 0x11, 0x11, 0x0e}; diff --git a/yarrg/icons/query.xbm b/yarrg/icons/query.xbm new file mode 100644 index 0000000..1281460 --- /dev/null +++ b/yarrg/icons/query.xbm @@ -0,0 +1,4 @@ +#define no-owner_width 5 +#define no-owner_height 9 +static unsigned char no-owner_bits[] = { + 0x0e, 0x11, 0x10, 0x10, 0x08, 0x04, 0x04, 0x00, 0x04}; diff --git a/yarrg/iconsdir/sl.xbm b/yarrg/icons/sl.xbm similarity index 100% rename from yarrg/iconsdir/sl.xbm rename to yarrg/icons/sl.xbm diff --git a/yarrg/iconsdir/unlocked.xbm b/yarrg/icons/unlocked.xbm similarity index 61% rename from yarrg/iconsdir/unlocked.xbm rename to yarrg/icons/unlocked.xbm index 545fc0b..b98cc07 100644 --- a/yarrg/iconsdir/unlocked.xbm +++ b/yarrg/icons/unlocked.xbm @@ -1,4 +1,4 @@ #define unlocked_width 5 #define unlocked_height 9 static unsigned char unlocked_bits[] = { - 0x00, 0x02, 0x05, 0x05, 0x04, 0x1c, 0x1c, 0x14, 0x1c}; + 0x06, 0x09, 0x10, 0x10, 0x08, 0x1f, 0x11, 0x11, 0x1f}; diff --git a/yarrg/iconsdir/wb.xbm b/yarrg/icons/wb.xbm similarity index 100% rename from yarrg/iconsdir/wb.xbm rename to yarrg/icons/wb.xbm diff --git a/yarrg/iconsdir/wf.xbm b/yarrg/icons/wf.xbm similarity index 100% rename from yarrg/iconsdir/wf.xbm rename to yarrg/icons/wf.xbm diff --git a/yarrg/iconsdir/xe.xbm b/yarrg/icons/xe.xbm similarity index 100% rename from yarrg/iconsdir/xe.xbm rename to yarrg/icons/xe.xbm diff --git a/yarrg/iconsdir/backup/ct.xbm b/yarrg/iconsdir/backup/ct.xbm deleted file mode 100644 index 9e0256b..0000000 --- a/yarrg/iconsdir/backup/ct.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define ct_width 12 -#define ct_height 10 -static unsigned char ct_bits[] = { - 0x00, 0x00, 0x20, 0x00, 0x60, 0x00, 0xa0, 0x00, 0x60, 0x01, 0xb8, 0x01, - 0x68, 0x01, 0xb8, 0x00, 0x60, 0x00, 0x00, 0x00}; diff --git a/yarrg/iconsdir/backup/ls.xbm b/yarrg/iconsdir/backup/ls.xbm deleted file mode 100644 index ba462f0..0000000 --- a/yarrg/iconsdir/backup/ls.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define ls_width 12 -#define ls_height 10 -static unsigned char ls_bits[] = { - 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x54, 0x05, 0xa8, 0x0a, 0xa8, 0x0a, - 0xa8, 0x0a, 0x54, 0x05, 0xfe, 0x03, 0x00, 0x00}; diff --git a/yarrg/iconsdir/backup/mb.xbm b/yarrg/iconsdir/backup/mb.xbm deleted file mode 100644 index 4873d27..0000000 --- a/yarrg/iconsdir/backup/mb.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define mb_width 12 -#define mb_height 10 -static unsigned char mb_bits[] = { - 0x00, 0x00, 0x40, 0x00, 0xc8, 0x00, 0x58, 0x01, 0xe8, 0x02, 0x4e, 0x03, - 0xca, 0x02, 0x6e, 0x01, 0xd8, 0x00, 0x00, 0x00}; diff --git a/yarrg/iconsdir/backup/mg.xbm b/yarrg/iconsdir/backup/mg.xbm deleted file mode 100644 index 5e3afeb..0000000 --- a/yarrg/iconsdir/backup/mg.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define mg_width 12 -#define mg_height 10 -static unsigned char mg_bits[] = { - 0x20, 0x00, 0x60, 0x00, 0xa4, 0x02, 0x6c, 0x05, 0xb4, 0x09, 0x64, 0x09, - 0xa7, 0x09, 0x65, 0x09, 0xb7, 0x0d, 0x6c, 0x07}; diff --git a/yarrg/iconsdir/bg.xbm b/yarrg/iconsdir/bg.xbm deleted file mode 100644 index 583f3a1..0000000 --- a/yarrg/iconsdir/bg.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define bg_width 12 -#define bg_height 10 -static unsigned char bg_bits[] = { - 0x10, 0x00, 0x30, 0x00, 0x50, 0x00, 0x92, 0x00, 0x16, 0x01, 0x1a, 0x02, - 0x12, 0x04, 0xe2, 0x0f, 0x42, 0x00, 0xfe, 0x00 }; diff --git a/yarrg/iconsdir/mg.xbm b/yarrg/iconsdir/mg.xbm deleted file mode 100644 index e4c457d..0000000 --- a/yarrg/iconsdir/mg.xbm +++ /dev/null @@ -1,5 +0,0 @@ -#define mf_width 12 -#define mf_height 10 -static unsigned char mf_bits[] = { - 0x20, 0x00, 0x68, 0x01, 0xb8, 0x03, 0x28, 0x05, 0x2c, 0x09, 0x2a, 0x09, - 0xb9, 0x05, 0x6f, 0x03, 0x28, 0x01, 0xff, 0x0f}; diff --git a/yarrg/where-vessels b/yarrg/where-vessels index adf76eb..ec4394b 100755 --- a/yarrg/where-vessels +++ b/yarrg/where-vessels @@ -193,15 +193,6 @@ proc note-info {lno vid name island description} { lappend note_infos [list $lno $vid $name $island $description] } -proc canvas-horiz-stack {xvar y type args} { - upvar 1 $xvar x - global canvas - set id [eval $canvas create $type $x $y $args] - set bbox [$canvas bbox $id] - set x [lindex $bbox 2] - return $id -} - proc display-note-infos {} { global note_infos note_missings notes @@ -273,7 +264,7 @@ proc vesselclasses-init {} { set vc_game2code($game) $code set vc_code2abbrev($code) $abbrev set vc_code2full($code) $full - image create bitmap ship-icon/$abbrev -file iconsdir/$abbrev.xbm + image create bitmap ship-icon/$abbrev -file icons/$abbrev.xbm } } @@ -283,20 +274,50 @@ proc code2abbrev-lock {lockown} { append abbrev [lindex {= - ?} [regsub {\D} $notown 2]] } -proc code2abbrev {code} { +proc canvas-horiz-stack {xvar y bind type args} { + upvar 1 $xvar x + upvar 1 canvas canvas + set id [eval $canvas create $type $x $y $args] + set bbox [$canvas bbox $id] + set x [lindex $bbox 2] + $canvas bind $id $bind + return $id +} + +proc code2canvas {code canvas x yvar qty qtylen bind} { global vc_code2abbrev + upvar 1 $yvar y manyset [split $code _] inport class subclass lockown xabbrev - set abbrev {} - append abbrev [lindex {? {}} $inport] - append abbrev $vc_code2abbrev($class) - append abbrev $subclass - append abbrev [code2abbrev-lock $lockown] - append abbrev $xabbrev + set stackx $x + incr stackx 2 + + append qty [lindex {? {}} $inport] + set qty [format "%${qtylen}s" $qty] + + set qtyid [canvas-horiz-stack stackx $y $bind \ + text -anchor nw -font fixed -text $qty] - debug "CODE2ABBREV $code $abbrev" - return $abbrev + incr stackx -1 + canvas-horiz-stack stackx [expr {$y+2}] $bind \ + image -anchor nw -image ship-icon/$vc_code2abbrev($class) + incr stackx + + canvas-horiz-stack stackx $y $bind \ + text -anchor nw -font fixed -text \ + "$subclass[code2abbrev-lock $lockown]$xabbrev" + + set bbox [$canvas bbox $qtyid] + set ny [lindex $bbox 3] + set bid [$canvas create rectangle \ + $x $y $stackx $ny \ + -fill white] + + set y $ny + $canvas lower $bid $qtyid + + $canvas bind $bid $bind } proc show-report-decode {code} { @@ -338,7 +359,10 @@ proc show-report-decode {code} { set filters {} proc filter-values/size {} { global vc_codes; return $vc_codes } -proc filter-map/size {code} { upvar #0 vc_code2abbrev($code) abb; return $abb } +proc filter-icon/size {code} { + upvar #0 vc_code2abbrev($code) abb + return ship-icon/$abb +} proc filter-default/size {code} { return 1 } proc filter-says-yes/size {codel} { set sizecode [lindex $codel 1] @@ -398,13 +422,17 @@ proc make-tickbox-filter {fil label rows inrow} { if {!$inrow} { set inrow [expr {($nvalues + $rows) / $rows}] } - + set noicons [catch { info args filter-icon/$fil }] for {set ix 0} {$ix < $nvalues} {incr ix} { set val [lindex $values $ix] set vars($val) [filter-default/$fil $val] checkbutton $fw.$ix -variable filter_${fil}($val) \ - -text [filter-map/$fil $val] -font fixed \ - -command redraw-needed + -font fixed -command redraw-needed + if {!$noicons} { + $fw.$ix configure -image [filter-icon/$fil $val] -height 16 + } else { + $fw.$ix configure -text [filter-map/$fil $val] + } grid configure $fw.$ix -sticky sw \ -row [expr {$ix / $inrow}] \ -column [expr {$ix % $inrow}] @@ -657,7 +685,6 @@ proc redraw-needed {} { proc draw {} { global chart found isleloc canvas redraw_after - global vc_code2abbrev catch { after cancel $redraw_after } catch { unset redraw_after } @@ -678,8 +705,6 @@ proc draw {} { if {![filters-say-yes $code]} continue - set abbrev [code2abbrev $code] - if {[string compare $lastislandname $islandname]} { manyset $isleloc($islandname) x y set x [coord $x] @@ -687,40 +712,10 @@ proc draw {} { set lastislandname $islandname # debug "START Y $y" } - set text $abbrev - regsub -all {[0-9]} $text {} text - if {$c > 1} { - set qty [format "%2d" $c] - } else { - set qty [format " " $c] - } - regsub {[a-z][a-z]} $text {} text - - set stackx $x - incr stackx 2 - set tid [canvas-horiz-stack stackx $y \ - text -anchor nw -font fixed -text $qty] - incr stackx -1 - canvas-horiz-stack stackx [expr {$y+2}] \ - image -anchor nw -image ship-icon/$vc_code2abbrev([lindex [split $code _] 1]) - incr stackx - canvas-horiz-stack stackx $y \ - text -anchor nw -font fixed -text $text - - set bbox [$canvas bbox $tid] - set ny [lindex $bbox 3] - puts "$tid $bbox" - set bid [$canvas create rectangle \ - $x $y $stackx $ny \ - -fill white] - - set y $ny - $canvas lower $bid $tid - - $canvas bind $tid [list show-report $islandname $code] - $canvas bind $bid [list show-report $islandname $code] - manyset $bbox dummy dummy dummy y + if {$c > 1} { set qty [format %d $c] } else { set qty {} } + code2canvas $code $canvas $x y $qty 2 \ + [list show-report $islandname $code] # debug "NEW Y $y" } @@ -929,14 +924,7 @@ proc widgets-setup {} { label .cp.report.island -text { } - frame .cp.report.abbrev -background black - glset report_abbrev { } - entry .cp.report.abbrev.abbrev -state readonly \ - -textvariable report_abbrev \ - -borderwidth 0 -relief flat -width 0 \ - -highlightbackground white \ - -readonlybackground white -foreground black - pack .cp.report.abbrev.abbrev -side left -padx 1 -pady 1 + canvas .cp.report.abbrev -width 1 -height 15 frame .cp.report.code label .cp.report.code.lab -text Code: @@ -962,9 +950,14 @@ proc report-set {sw val} { .cp.report.details.$sw configure -text $val } proc show-report {islandname code} { .cp.report.island configure -text $islandname - glset report_code $code - glset report_abbrev [code2abbrev $code] + .cp.report.abbrev delete all + set y 2 + code2canvas $code .cp.report.abbrev 5 y {} 0 {} + manyset [.cp.report.abbrev bbox all] minx dummy maxx dummy + .cp.report.abbrev configure -width [expr {$maxx-$minx+4}] + + glset report_code $code show-report-decode $code set kk "$islandname $code" -- 2.30.2