Re: [Kicad-developers] [PATCH] Add live footprint filtering in modview window

2017-10-31 Thread Wayne Stambaugh
On 10/31/2017 5:01 PM, Oliver Walters wrote:
> How should I proceed here then?
> 
> I would like to see the various libraries being "cached" in the
> background, but this is increasing the scope of the work by a large factor.
> 
> One thing I have noticed:
> 
> In eeschema when you launch the component viewer, it (on first run) maps
> and caches all the footprint libraries. This can take AGES (especially
> on Windows). However on subsequent launches of the component viewer it
> appears instantly. It appears to be keeping a static map of the
> footprint library data.
> 
> a) Would this be an acceptable approach for the footprint viewer window

Sure.  Code reuse is a good thing.  I'm pretty sure the threaded
footprint library code is split out from the component chooser so it
should be reusable.

> b) What happens when the library data changes externally? Does component
> viewer need to be reloaded?

No, only the library that changed gets reloaded the next time it's
accessed.  It is not automatic.  I thought about using wxFileWatcher but
that could be a lot of overhead for little net gain.  See the pcb plugin
cache() functions.

> c) Can we globally perform this caching in a background thread when
> KiCad launches? This will hide the large pauses (up to a minute under
> Windows) from the user...

Yes, this should be done as a project element so that it can be accessed
from all of the main windows.  Please keep in mind, this could be a lot
of work and given that we are nearing a stable 5 release feature freeze,
so if it's not by then it will not make it into the stable 5 release.

> 
> Oliver
> 
> On Tue, Oct 31, 2017 at 11:32 PM, Wayne Stambaugh  > wrote:
> 
> On 10/31/2017 1:25 AM, Oliver Walters wrote:
> > Hmm, I had thought that there was a way to load only the *names* of
> > footprints, rather than individually parsing each footprint file. It
> > appears that this is not the case. Any suggestions on how the speed
> > could be improved? Currently I'm reading out all the footprint names in
> > each footprint library and only storing the names (wxString) rather than
> > the MODULE* objects. However, I still have to parse the entire library
> > on load.
> >
> > Ideally, I think it would be good to just read in the names, and then
> > load and display individual MODULE objects on demand.. Is this possible?
> 
> This is possible (although not implemented) for library types (kicad,
> geda) that use one file per footprint.  You could just read the file
> names from the folder and load the files as required.  If you want to
> search any other properties of the footprint, then you will have to load
> all of the footprints anyway.  I don't know if this would be worth the
> effort.
> 
> For library types that contain multiple footprints per file (legacy,
> Eagle), this wouldn't make much sense.  Parsing the entire file just to
> pick out the footprint names probably isn't going to save you very much
> time.
> 
> >
> > On Tue, Oct 31, 2017 at 10:40 AM, Wayne Stambaugh  
> > >> wrote:
> >
> >     On 10/30/2017 5:23 PM, Oliver Walters wrote:
> >     > Thanks for the suggestions on fixing the text. I have that 
> sorted. 
> >     >
> >     > I will look into different ways of caching footprint data so it 
> is quicker. 
> >     >
> >     > Wayne, I didn't know about FOOTPRINT_FILTER I will switch to 
> using that
> >     > instead (and provide regex search).
> >
> >     Thanks Oliver!
> >
> >     >
> >     > On 31 Oct 2017 06:55, "Seth Hillbrand"  
> >
> >     > 
>   >     >
> >     >     On Mon, Oct 30, 2017 at 11:42 AM, Wayne Stambaugh
> >     >     mailto:stambau...@gmail.com>
> >
> >     
>  >     >
> >     >         On 10/30/2017 1:16 PM, Seth Hillbrand wrote:
> >     >         > Oliver, this is neat and very helpful.
> >     >         >
> >     >         > The greyed-out thing is a wx2.8 bug.  You can work
> >     around it by setting
> >     >         > the foreground color when updating the filter like
> this:
> >     >         >  
> >     >         >  void FOOTPRINT_VIEWER_FRAME::OnFilterUpdated(
> >     wxCommandEvent& event )
> >     >         >  {
> >     >         > +    // Workaround wx2.8 bug showing greyed color
> >     >         

Re: [Kicad-developers] [PATCH] Right click option to change layer and render color

2017-10-31 Thread Thomas Kindler
On Thu, September 21, 2017 17:25, Seppe Stas wrote:
> This patch makes it possible to change the color of layers and render
> options using the right click menu. [..]

I think having a checkbox for "High Contrast Mode" (Hotkey H) would be a
nice addition to this menu!

best regards,
Thomas

___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp


Re: [Kicad-developers] [RFC] New color selector for GAL canvas, and more easy support of opacity.

2017-10-31 Thread Thomas Kindler
On Mon, July 17, 2017 19:20, jp charras wrote:
> Attached a patch which adds a new (and I hope better) color selector for
> GAL canvas, with support of opacity.

I think I found a small bug - when the opacity is changed using the "{" /
"}" hotkeys, the value in the dialog isn't updated.

best regards,
Thomas

___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp


Re: [Kicad-developers] [PATCH] Add live footprint filtering in modview window

2017-10-31 Thread Oliver Walters
How should I proceed here then?

I would like to see the various libraries being "cached" in the background,
but this is increasing the scope of the work by a large factor.

One thing I have noticed:

In eeschema when you launch the component viewer, it (on first run) maps
and caches all the footprint libraries. This can take AGES (especially on
Windows). However on subsequent launches of the component viewer it appears
instantly. It appears to be keeping a static map of the footprint library
data.

a) Would this be an acceptable approach for the footprint viewer window
b) What happens when the library data changes externally? Does component
viewer need to be reloaded?
c) Can we globally perform this caching in a background thread when KiCad
launches? This will hide the large pauses (up to a minute under Windows)
from the user...

Oliver

On Tue, Oct 31, 2017 at 11:32 PM, Wayne Stambaugh 
wrote:

> On 10/31/2017 1:25 AM, Oliver Walters wrote:
> > Hmm, I had thought that there was a way to load only the *names* of
> > footprints, rather than individually parsing each footprint file. It
> > appears that this is not the case. Any suggestions on how the speed
> > could be improved? Currently I'm reading out all the footprint names in
> > each footprint library and only storing the names (wxString) rather than
> > the MODULE* objects. However, I still have to parse the entire library
> > on load.
> >
> > Ideally, I think it would be good to just read in the names, and then
> > load and display individual MODULE objects on demand.. Is this possible?
>
> This is possible (although not implemented) for library types (kicad,
> geda) that use one file per footprint.  You could just read the file
> names from the folder and load the files as required.  If you want to
> search any other properties of the footprint, then you will have to load
> all of the footprints anyway.  I don't know if this would be worth the
> effort.
>
> For library types that contain multiple footprints per file (legacy,
> Eagle), this wouldn't make much sense.  Parsing the entire file just to
> pick out the footprint names probably isn't going to save you very much
> time.
>
> >
> > On Tue, Oct 31, 2017 at 10:40 AM, Wayne Stambaugh  > > wrote:
> >
> > On 10/30/2017 5:23 PM, Oliver Walters wrote:
> > > Thanks for the suggestions on fixing the text. I have that sorted.
> > >
> > > I will look into different ways of caching footprint data so it is
> quicker.
> > >
> > > Wayne, I didn't know about FOOTPRINT_FILTER I will switch to using
> that
> > > instead (and provide regex search).
> >
> > Thanks Oliver!
> >
> > >
> > > On 31 Oct 2017 06:55, "Seth Hillbrand"  
> > > >>
> wrote:
> > >
> > > On Mon, Oct 30, 2017 at 11:42 AM, Wayne Stambaugh
> > > mailto:stambau...@gmail.com>
> > >>wrote:
> > >
> > > On 10/30/2017 1:16 PM, Seth Hillbrand wrote:
> > > > Oliver, this is neat and very helpful.
> > > >
> > > > The greyed-out thing is a wx2.8 bug.  You can work
> > around it by setting
> > > > the foreground color when updating the filter like this:
> > > >
> > > >  void FOOTPRINT_VIEWER_FRAME::OnFilterUpdated(
> > wxCommandEvent& event )
> > > >  {
> > > > +// Workaround wx2.8 bug showing greyed color
> > > > +if( m_searchBox->GetValue() !=
> > m_searchBox->GetDescriptiveText() )
> > > > +m_searchBox->SetForegroundColour(
> > > > m_searchBox->GetDefaultAttributes().colFg );
> > > > +
> > > >  // Filter is non case sensitive
> > > >  wxString filter = m_searchBox->GetValue().Lower();
> > > >
> > > > The searchbox handles resetting it to grey on idle()
> > when the text is empty.
> > >
> > > Don't you mean wx 3.0?  CMake should not even generate the
> > build
> > > configuration files without wx 3.0 or greater.
> > >
> > >
> > > Hmm... This was an issue back in 2.8 that appears to be only
> > partly
> > > fixed.  The workaround I suggest above is functional but, for
> > this,
> > > we can also execute a cleaner fix by setting the descriptive
> > text in
> > > the declaration:
> > >
> > > @@ -67,9 +67,10 @@ void FOOTPRINT_VIEWER_FRAME::
> ReCreateHToolbar()
> > >  KiBitmap( module_xpm ),
> > >  _( "Select footprint to
> > browse" ) );
> > >
> > > -m_searchBox = new wxSearchCtrl( m_mainToolBar,
> > > ID_MODVIEW_SEARCH_TEXT );
> > > +m_searchBo

Re: [Kicad-developers] [PATCH] Add live footprint filtering in modview window

2017-10-31 Thread Fabrizio Tappero
hi Guys,
this is a great feature. It would be a good thing to have a gray suggestion
often used in webpages and phone apps. Example here:

https://storage.googleapis.com/material-design/publish/material_v_12/assets/0B5ZSepuCX1xOOURmSHNjdktDR28/discoverable-extracted-label1.png


cheers
Fabrizio



On Tue, Oct 31, 2017 at 1:32 PM, Wayne Stambaugh 
wrote:

> On 10/31/2017 1:25 AM, Oliver Walters wrote:
> > Hmm, I had thought that there was a way to load only the *names* of
> > footprints, rather than individually parsing each footprint file. It
> > appears that this is not the case. Any suggestions on how the speed
> > could be improved? Currently I'm reading out all the footprint names in
> > each footprint library and only storing the names (wxString) rather than
> > the MODULE* objects. However, I still have to parse the entire library
> > on load.
> >
> > Ideally, I think it would be good to just read in the names, and then
> > load and display individual MODULE objects on demand.. Is this possible?
>
> This is possible (although not implemented) for library types (kicad,
> geda) that use one file per footprint.  You could just read the file
> names from the folder and load the files as required.  If you want to
> search any other properties of the footprint, then you will have to load
> all of the footprints anyway.  I don't know if this would be worth the
> effort.
>
> For library types that contain multiple footprints per file (legacy,
> Eagle), this wouldn't make much sense.  Parsing the entire file just to
> pick out the footprint names probably isn't going to save you very much
> time.
>
> >
> > On Tue, Oct 31, 2017 at 10:40 AM, Wayne Stambaugh  > > wrote:
> >
> > On 10/30/2017 5:23 PM, Oliver Walters wrote:
> > > Thanks for the suggestions on fixing the text. I have that sorted.
> > >
> > > I will look into different ways of caching footprint data so it is
> quicker.
> > >
> > > Wayne, I didn't know about FOOTPRINT_FILTER I will switch to using
> that
> > > instead (and provide regex search).
> >
> > Thanks Oliver!
> >
> > >
> > > On 31 Oct 2017 06:55, "Seth Hillbrand"  
> > > >>
> wrote:
> > >
> > > On Mon, Oct 30, 2017 at 11:42 AM, Wayne Stambaugh
> > > mailto:stambau...@gmail.com>
> > >>wrote:
> > >
> > > On 10/30/2017 1:16 PM, Seth Hillbrand wrote:
> > > > Oliver, this is neat and very helpful.
> > > >
> > > > The greyed-out thing is a wx2.8 bug.  You can work
> > around it by setting
> > > > the foreground color when updating the filter like this:
> > > >
> > > >  void FOOTPRINT_VIEWER_FRAME::OnFilterUpdated(
> > wxCommandEvent& event )
> > > >  {
> > > > +// Workaround wx2.8 bug showing greyed color
> > > > +if( m_searchBox->GetValue() !=
> > m_searchBox->GetDescriptiveText() )
> > > > +m_searchBox->SetForegroundColour(
> > > > m_searchBox->GetDefaultAttributes().colFg );
> > > > +
> > > >  // Filter is non case sensitive
> > > >  wxString filter = m_searchBox->GetValue().Lower();
> > > >
> > > > The searchbox handles resetting it to grey on idle()
> > when the text is empty.
> > >
> > > Don't you mean wx 3.0?  CMake should not even generate the
> > build
> > > configuration files without wx 3.0 or greater.
> > >
> > >
> > > Hmm... This was an issue back in 2.8 that appears to be only
> > partly
> > > fixed.  The workaround I suggest above is functional but, for
> > this,
> > > we can also execute a cleaner fix by setting the descriptive
> > text in
> > > the declaration:
> > >
> > > @@ -67,9 +67,10 @@ void FOOTPRINT_VIEWER_FRAME::
> ReCreateHToolbar()
> > >  KiBitmap( module_xpm ),
> > >  _( "Select footprint to
> > browse" ) );
> > >
> > > -m_searchBox = new wxSearchCtrl( m_mainToolBar,
> > > ID_MODVIEW_SEARCH_TEXT );
> > > +m_searchBox = new wxSearchCtrl( m_mainToolBar,
> > > ID_MODVIEW_SEARCH_TEXT,
> > > +_( "Enter filter string" ) );
> > >  m_searchBox->SetMinSize( wxSize( 250, 30 ) );
> > > -m_searchBox->SetDescriptiveText( _( "Enter filter
> > string" ) );
> > >
> > >
> > >
> > > ___
> > > Mailing list: https://launchpad.net/~kicad-developers
> > 
> > > 

Re: [Kicad-developers] [PATCH] Add live footprint filtering in modview window

2017-10-31 Thread Wayne Stambaugh
On 10/31/2017 1:25 AM, Oliver Walters wrote:
> Hmm, I had thought that there was a way to load only the *names* of
> footprints, rather than individually parsing each footprint file. It
> appears that this is not the case. Any suggestions on how the speed
> could be improved? Currently I'm reading out all the footprint names in
> each footprint library and only storing the names (wxString) rather than
> the MODULE* objects. However, I still have to parse the entire library
> on load.
> 
> Ideally, I think it would be good to just read in the names, and then
> load and display individual MODULE objects on demand.. Is this possible?

This is possible (although not implemented) for library types (kicad,
geda) that use one file per footprint.  You could just read the file
names from the folder and load the files as required.  If you want to
search any other properties of the footprint, then you will have to load
all of the footprints anyway.  I don't know if this would be worth the
effort.

For library types that contain multiple footprints per file (legacy,
Eagle), this wouldn't make much sense.  Parsing the entire file just to
pick out the footprint names probably isn't going to save you very much
time.

> 
> On Tue, Oct 31, 2017 at 10:40 AM, Wayne Stambaugh  > wrote:
> 
> On 10/30/2017 5:23 PM, Oliver Walters wrote:
> > Thanks for the suggestions on fixing the text. I have that sorted. 
> >
> > I will look into different ways of caching footprint data so it is 
> quicker. 
> >
> > Wayne, I didn't know about FOOTPRINT_FILTER I will switch to using that
> > instead (and provide regex search).
> 
> Thanks Oliver!
> 
> >
> > On 31 Oct 2017 06:55, "Seth Hillbrand"  
> > >> 
> wrote:
> >
> >     On Mon, Oct 30, 2017 at 11:42 AM, Wayne Stambaugh
> >     mailto:stambau...@gmail.com>
> >>wrote:
> >
> >         On 10/30/2017 1:16 PM, Seth Hillbrand wrote:
> >         > Oliver, this is neat and very helpful.
> >         >
> >         > The greyed-out thing is a wx2.8 bug.  You can work
> around it by setting
> >         > the foreground color when updating the filter like this:
> >         >  
> >         >  void FOOTPRINT_VIEWER_FRAME::OnFilterUpdated(
> wxCommandEvent& event )
> >         >  {
> >         > +    // Workaround wx2.8 bug showing greyed color
> >         > +    if( m_searchBox->GetValue() !=
> m_searchBox->GetDescriptiveText() )
> >         > +        m_searchBox->SetForegroundColour(
> >         > m_searchBox->GetDefaultAttributes().colFg );
> >         > +
> >         >      // Filter is non case sensitive
> >         >      wxString filter = m_searchBox->GetValue().Lower();
> >         >
> >         > The searchbox handles resetting it to grey on idle()
> when the text is empty.
> >
> >         Don't you mean wx 3.0?  CMake should not even generate the
> build
> >         configuration files without wx 3.0 or greater.
> >
> >
> >     Hmm... This was an issue back in 2.8 that appears to be only
> partly
> >     fixed.  The workaround I suggest above is functional but, for
> this,
> >     we can also execute a cleaner fix by setting the descriptive
> text in
> >     the declaration:
> >
> >     @@ -67,9 +67,10 @@ void FOOTPRINT_VIEWER_FRAME::ReCreateHToolbar()
> >                                      KiBitmap( module_xpm ),
> >                                      _( "Select footprint to
> browse" ) );
> >      
> >     -        m_searchBox = new wxSearchCtrl( m_mainToolBar,
> >     ID_MODVIEW_SEARCH_TEXT );
> >     +        m_searchBox = new wxSearchCtrl( m_mainToolBar,
> >     ID_MODVIEW_SEARCH_TEXT,
> >     +                _( "Enter filter string" ) );
> >              m_searchBox->SetMinSize( wxSize( 250, 30 ) );
> >     -        m_searchBox->SetDescriptiveText( _( "Enter filter
> string" ) );
> >
> >
> >
> >     ___
> >     Mailing list: https://launchpad.net/~kicad-developers
> 
> >      >
> >     Post to     : kicad-developers@lists.launchpad.net
> 
> >      >
> >     Unsubscribe : https://launchpad.net/~kicad-developers
> 
> >      >
> >     More help   : https://help.laun

Re: [Kicad-developers] when to release kicad-5.0

2017-10-31 Thread Wayne Stambaugh
We are very close to a feature freeze and creating a 5 stable branch.
Once that is done, it typically takes a few months to make sure there
are no critical or major bugs before we can release.  The goal is to
have it released before FOSDEM 2018 so I have some good news to deliver
during the KiCad presentation.

On 10/30/2017 8:56 PM, Bang He wrote:
> kicad-5.0 have developed for a long time. so i want to ask when the
> kicad-5.0 is going to release.
> 
> 
> ___
> Mailing list: https://launchpad.net/~kicad-developers
> Post to : kicad-developers@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help   : https://help.launchpad.net/ListHelp
> 

___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp


[Kicad-developers] [PATCH 2/3] vector2d: Fix traits usage and use std::numeric_limits

2017-10-31 Thread Marvin Schmidt
---
 include/math/vector2d.h | 9 +
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/include/math/vector2d.h b/include/math/vector2d.h
index 8bf2da588..d67f9b72f 100644
--- a/include/math/vector2d.h
+++ b/include/math/vector2d.h
@@ -29,8 +29,8 @@
 #define VECTOR2D_H_
 
 #include 
-#include 
 #include 
+#include 
 #include 
 
 #include 
@@ -55,8 +55,6 @@ template <>
 struct VECTOR2_TRAITS
 {
 typedef int64_t extended_type;
-static const extended_type ECOORD_MAX = 0x7fffULL;
-static const extended_type ECOORD_MIN = 0x8000ULL;
 };
 
 // Forward declarations for template friends
@@ -74,12 +72,15 @@ std::ostream& operator<<( std::ostream& aStream, const 
VECTOR2& aVector );
  *
  */
 template 
-class VECTOR2 : public VECTOR2_TRAITS
+class VECTOR2
 {
 public:
 typedef typename VECTOR2_TRAITS::extended_type extended_type;
 typedef T coord_type;
 
+static constexpr extended_type ECOORD_MAX = 
std::numeric_limits::max();
+static constexpr extended_type ECOORD_MIN = 
std::numeric_limits::min();
+
 T x, y;
 
 // Constructors
-- 
2.14.1


___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp


[Kicad-developers] [PATCH 3/3] box2: Remove wrong use of typename keyword

2017-10-31 Thread Marvin Schmidt
---
 include/math/box2.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/math/box2.h b/include/math/box2.h
index 5bf6ddd03..fb6fd9d5c 100644
--- a/include/math/box2.h
+++ b/include/math/box2.h
@@ -47,7 +47,7 @@ private:
 public:
 typedef typename Vec::coord_type coord_type;
 typedef typename Vec::extended_type  ecoord_type;
-typedef typename std::numeric_limits coord_limits;
+typedef std::numeric_limits  coord_limits;
 
 BOX2() {};
 
-- 
2.14.1


___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp


[Kicad-developers] [PATCH 1/3] vector2d: Remove duplicate #include

2017-10-31 Thread Marvin Schmidt
---
 include/math/vector2d.h | 1 -
 1 file changed, 1 deletion(-)

diff --git a/include/math/vector2d.h b/include/math/vector2d.h
index abe3734ac..8bf2da588 100644
--- a/include/math/vector2d.h
+++ b/include/math/vector2d.h
@@ -32,7 +32,6 @@
 #include 
 #include 
 #include 
-#include 
 
 #include 
 
-- 
2.14.1


___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp


[Kicad-developers] [PATCH 0/3] Minor fixes for VECTOR2 and BOX2

2017-10-31 Thread Marvin Schmidt
I was irritated by the usage of the vector_traits class as you usually
use it to gather more information about a certain type using
something like `traits::property`. Here the vector2d classes
queries the traits class to get the extended coordinate type but also
derives from it to get the limits of that type which are hardcoded in
the traits class. The second patch removes the hardcoded limits from
the traits class and the inheritance of the vector2d class from the traits
class. Instead the vector2d class uses the std::numeric_limits facility
to get the limits of the extended coordinate type it got through the
traits class

The other two patches are just minor fixes. The wrong use of the
typename keyword in the box2 class might have been triggering a bug
in the MSVC compiler though (not sure about that as I can't test it,
just seems possible from workaround I've seen)

Marvin Schmidt (3):
  vector2d: Remove duplicate #include
  vector2d: Fix traits usage and use std::numeric_limits
  box2: Remove wrong use of typename keyword

 include/math/box2.h |  2 +-
 include/math/vector2d.h | 10 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

-- 
2.14.1


___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp


Re: [Kicad-developers] Strange behavior of draw panel gal focus.

2017-10-31 Thread Maciej Sumiński
Hi Bang,

You need to build KiCad with debug symbols enabled. It can surely be
done using MSYS2 [1], but I think there are developers able to build
KiCad using MS Visual Studio as well. If you prefer the latter, perhaps
someone else can give you some details, I do not know the exact steps.

If you go for MSYS2, then simply run 'gdb path/to/kicad.exe' and the
rest is common gdb debugging. The only exception is Ctrl+C does not work
there, so it is a bit cumbersome to interrupt the program, but it is
possible [2].

Regards,
Orson

1.
http://docs.kicad-pcb.org/doxygen/md_Documentation_development_compiling.html
[Building KiCad on Windows]
2. http://www.mingw.org/wiki/Workaround_for_GDB_Ctrl_C_Interrupt

On 10/31/2017 01:44 AM, Bang He wrote:
> how to debug on win7
> 
> On Mon, Oct 30, 2017 at 9:40 PM, Maciej Sumiński 
> wrote:
> 
>> Hi Jean-Pierre,
>>
>> Everything works as expected on Linux, with or without the patch. I
>> recall having some other focus problems in the past, so there are more
>> workarounds in common/draw_panel_gal.cpp.
>>
>> Perhaps there is a way to simplify the code related to focus handling or
>> the event handlers setup is incorrect? IIRC, I added the workarounds to
>> make the Tool Dispatcher receive key up/down events.
>>
>> Regards,
>> Orson
>>
>> On 10/30/2017 11:54 AM, jp charras wrote:
>>> Hi Orson,
>>>
>>> Could you have a look into this patch?
>>>
>>> It fixes (this it only a workaround) a very strange behavior of focus,
>> for the draw panel GAL.
>>> Sometimes the draw panel do not have the focus (and moreover do not
>> accept the focus) on W7 32 bits.
>>>
>>> It happens when 2 EDA_FRAME are opened, for instance the board editor
>> and the footprint viewer.
>>>
>>> When the 2 frame are shown on screen, no problem.
>>> But if you iconize one frame (for instance the footprint viewer) the
>> remaining frame does not
>>> receive some events (key events and mousewheel event).
>>>
>>> I had a look into this strange behavior and found 2 problems:
>>> 1 - When happens, the wxWindow::FindFocus() method returns nullptr (that
>> explains why some events
>>> are no longer received)
>>> 2 - And the active draw panel gal does not accept the focus (SetFocus()
>> do nothing). Only the main
>>> Draw Frame accepts SetFocus().
>>>
>>> This small patch gives the Focus to the main Draw Frame when
>> wxWindow::FindFocus() method returns
>>> nullptr.
>>>
>>> More strange:
>>> The first time the footprint viewer is iconized, the focus is lost.
>>> but if you raise and iconize the footprint viewer, the focus is OK.
>>>
>>> In short when iconizing n times the footprint viewer, if n is odd, the
>> focus is lost, and if n is
>>> even, the focus is OK.
>>>
>>> I also noticed (when reading the tool_dispatcher.cpp source) there is a
>> similar focus issue on OSX.
>>>
>>> Perhaps my workaround also fixes this OSX issue.
>>>
>>> Thanks.
>>>
>>
>>
>>
>> ___
>> Mailing list: https://launchpad.net/~kicad-developers
>> Post to : kicad-developers@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~kicad-developers
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
> 




signature.asc
Description: OpenPGP digital signature
___
Mailing list: https://launchpad.net/~kicad-developers
Post to : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp