kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #32108
[PATCH] Clarify disambiguation menu icons in Eeschema
Currently the disabiguation menu entries for the bus2bus and wire2bus
entries are both a straight, green wire. The attached patch replaces these
disambiguation icons with the icons from the menubar for consistency. It
now shows the bus2bus differently than the wire2bus.
Please note, that this patch proposes deleting an icon that would be not
used if we decided to use this patch. I didn't see any other unused icons
in the directory, so I assume that this is kosher but if the general policy
is to keep artwork in case it is needed, I'll revise.
-Seth
From 1fe1d92039e1ac01a2b20a274ba2bd44d42d48a6 Mon Sep 17 00:00:00 2001
From: Seth Hillbrand <hillbrand@xxxxxxxxxxx>
Date: Thu, 30 Nov 2017 19:33:22 -0800
Subject: [PATCH] Eeschema: Clarify disambiuation of entry types
Replace the disambiguation menu entry for
wire2bus and bus2bus entries with their menu icon.
---
bitmaps_png/CMakeLists.txt | 1 -
bitmaps_png/cpp_26/add_entry.cpp | 22 -------------
bitmaps_png/sources/add_entry.svg | 65 ---------------------------------------
eeschema/sch_bus_entry.cpp | 11 +++++--
eeschema/sch_bus_entry.h | 6 ++--
include/bitmaps.h | 1 -
6 files changed, 13 insertions(+), 93 deletions(-)
delete mode 100644 bitmaps_png/cpp_26/add_entry.cpp
delete mode 100644 bitmaps_png/sources/add_entry.svg
diff --git a/bitmaps_png/CMakeLists.txt b/bitmaps_png/CMakeLists.txt
index 9f486c1ff..5c64ac156 100644
--- a/bitmaps_png/CMakeLists.txt
+++ b/bitmaps_png/CMakeLists.txt
@@ -114,7 +114,6 @@ set( BMAPS_MID
add_corner
add_dashed_line
add_dimension
- add_entry
add_glabel
add_graphical_segments
add_graphical_polygon
diff --git a/bitmaps_png/cpp_26/add_entry.cpp b/bitmaps_png/cpp_26/add_entry.cpp
deleted file mode 100644
index eb4e7fd95..000000000
--- a/bitmaps_png/cpp_26/add_entry.cpp
+++ /dev/null
@@ -1,22 +0,0 @@
-
-/* Do not modify this file, it was automatically generated by the
- * PNG2cpp CMake script, using a *.png file as input.
- */
-
-#include <bitmaps.h>
-
-static const unsigned char png[] = {
- 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a, 0x00, 0x00, 0x00, 0x0d, 0x49, 0x48, 0x44, 0x52,
- 0x00, 0x00, 0x00, 0x1a, 0x00, 0x00, 0x00, 0x1a, 0x08, 0x06, 0x00, 0x00, 0x00, 0xa9, 0x4a, 0x4c,
- 0xce, 0x00, 0x00, 0x00, 0x56, 0x49, 0x44, 0x41, 0x54, 0x48, 0xc7, 0x63, 0x60, 0x18, 0x05, 0xa3,
- 0x60, 0x14, 0x8c, 0x02, 0xdc, 0xa0, 0x83, 0x81, 0x9f, 0xa1, 0x97, 0xc1, 0x99, 0xa1, 0x9b, 0xc1,
- 0x85, 0x2a, 0x18, 0x64, 0x16, 0xc8, 0x4c, 0x0c, 0xd0, 0xc3, 0x70, 0x15, 0x88, 0xff, 0x53, 0x19,
- 0x5f, 0x45, 0xb5, 0xe4, 0x3f, 0x03, 0x23, 0x50, 0xf0, 0x05, 0x0d, 0x2c, 0x7a, 0x01, 0x36, 0x1b,
- 0x05, 0xf4, 0x32, 0xa8, 0x01, 0x71, 0x11, 0xd0, 0xdb, 0xe5, 0x54, 0xc1, 0x3d, 0x0c, 0x85, 0x60,
- 0x33, 0x47, 0xc1, 0x28, 0x18, 0x05, 0xa3, 0x60, 0x04, 0x01, 0x00, 0x9e, 0x8a, 0x6c, 0x45, 0x42,
- 0x41, 0x17, 0x6c, 0x00, 0x00, 0x00, 0x00, 0x49, 0x45, 0x4e, 0x44, 0xae, 0x42, 0x60, 0x82,
-};
-
-const BITMAP_OPAQUE add_entry_xpm[1] = {{ png, sizeof( png ), "add_entry_xpm" }};
-
-//EOF
diff --git a/bitmaps_png/sources/add_entry.svg b/bitmaps_png/sources/add_entry.svg
deleted file mode 100644
index c97a47dd3..000000000
--- a/bitmaps_png/sources/add_entry.svg
+++ /dev/null
@@ -1,65 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<svg
- xmlns:dc="http://purl.org/dc/elements/1.1/"
- xmlns:cc="http://creativecommons.org/ns#"
- xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:svg="http://www.w3.org/2000/svg"
- xmlns="http://www.w3.org/2000/svg"
- xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
- xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
- height="26"
- width="26"
- version="1.1"
- id="svg2"
- inkscape:version="0.91 r13725"
- sodipodi:docname="add_entry.svg">
- <metadata
- id="metadata29">
- <rdf:RDF>
- <cc:Work
- rdf:about="">
- <dc:format>image/svg+xml</dc:format>
- <dc:type
- rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
- <dc:title />
- </cc:Work>
- </rdf:RDF>
- </metadata>
- <sodipodi:namedview
- pagecolor="#ffffff"
- bordercolor="#666666"
- borderopacity="1"
- objecttolerance="10"
- gridtolerance="10"
- guidetolerance="10"
- inkscape:pageopacity="0"
- inkscape:pageshadow="2"
- inkscape:window-width="1920"
- inkscape:window-height="1054"
- id="namedview27"
- showgrid="true"
- inkscape:zoom="32.472518"
- inkscape:cx="7.2770832"
- inkscape:cy="13.352066"
- inkscape:window-x="0"
- inkscape:window-y="0"
- inkscape:window-maximized="1"
- inkscape:current-layer="svg2"
- inkscape:snap-to-guides="false"
- inkscape:snap-grids="true">
- <inkscape:grid
- type="xygrid"
- id="grid2993"
- empspacing="5"
- visible="true"
- enabled="true"
- snapvisiblegridlinesonly="true" />
- </sodipodi:namedview>
- <defs
- id="defs4" />
- <path
- style="fill:none;stroke:#008c00;stroke-width:2.70000005;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
- d="m 3.3218892,12.080833 19.3562218,0"
- id="path2985"
- inkscape:connector-curvature="0" />
-</svg>
diff --git a/eeschema/sch_bus_entry.cpp b/eeschema/sch_bus_entry.cpp
index 9291b3963..7f0af6b85 100644
--- a/eeschema/sch_bus_entry.cpp
+++ b/eeschema/sch_bus_entry.cpp
@@ -280,9 +280,16 @@ wxString SCH_BUS_BUS_ENTRY::GetSelectMenuText() const
return wxString( _( "Bus to Bus Entry" ) );
}
-BITMAP_DEF SCH_BUS_ENTRY_BASE::GetMenuImage() const
+
+BITMAP_DEF SCH_BUS_WIRE_ENTRY::GetMenuImage() const
+{
+ return add_line2bus_xpm;
+}
+
+
+BITMAP_DEF SCH_BUS_BUS_ENTRY::GetMenuImage() const
{
- return add_entry_xpm;
+ return add_bus2bus_xpm;
}
diff --git a/eeschema/sch_bus_entry.h b/eeschema/sch_bus_entry.h
index d96dc9741..90bc07407 100644
--- a/eeschema/sch_bus_entry.h
+++ b/eeschema/sch_bus_entry.h
@@ -109,8 +109,6 @@ public:
void GetConnectionPoints( std::vector< wxPoint >& aPoints ) const override;
- BITMAP_DEF GetMenuImage() const override;
-
wxPoint GetPosition() const override { return m_pos; }
void SetPosition( const wxPoint& aPosition ) override { m_pos = aPosition; }
@@ -146,6 +144,8 @@ public:
wxString GetSelectMenuText() const override;
EDA_ITEM* Clone() const override;
+
+ BITMAP_DEF GetMenuImage() const override;
};
/**
@@ -168,6 +168,8 @@ public:
wxString GetSelectMenuText() const override;
EDA_ITEM* Clone() const override;
+
+ BITMAP_DEF GetMenuImage() const override;
};
#endif // _SCH_BUS_ENTRY_H_
diff --git a/include/bitmaps.h b/include/bitmaps.h
index fa2e71eda..ad838a889 100644
--- a/include/bitmaps.h
+++ b/include/bitmaps.h
@@ -39,7 +39,6 @@ EXTERN_BITMAP( add_component_xpm )
EXTERN_BITMAP( add_corner_xpm )
EXTERN_BITMAP( add_dashed_line_xpm )
EXTERN_BITMAP( add_dimension_xpm )
-EXTERN_BITMAP( add_entry_xpm )
EXTERN_BITMAP( add_glabel_xpm )
EXTERN_BITMAP( add_graphical_segments_xpm )
EXTERN_BITMAP( add_graphical_polygon_xpm )
--
2.11.0
Follow ups