← Back to team overview

kicad-developers team mailing list archive

Re: [Branch ~kicad-product-committers/kicad/product] Rev 6698: Pcbnew: remove dead macro code.

 

On 4/20/2016 3:09 AM, jp charras wrote:
> Le 19/04/2016 22:02, Andrey Fedorushkov a écrit :
>>
>> In attach is one of the files.
>> For example, a macro is very simple to make the ground skip and via between the microwave lines.
>> I wrote the "mini-guide" in the newsletter, how to use macros when my colleague Roman Bashkov completed code.
>> I can briefly repeat.
>> For example, it is necessary to do the Via group (eg two via) with some (different) pitch:
>> use hotkeys
>> macros 1 record
>> <ctrl+1> - X - <move cursor> - V - <End> - <PgUp> - X - <move cursor> - V - <End> - <PgUp> - <ctrl+1>
>> Move cursor to new pad (or point) and press <1>.
>>
>> The sequence hotkeys may be very different.
> 
> Like Wayne wrote, the macro code has some issues, never fixed, which make the macros hard to use, or
> not usable by most of users:
> 
> * First of all, on Windows, ctrl+1 does not generate a key event, therefore it is *not possible* to
> start a record. (On my computer, ctrl+1 is usable only on Linux).
> Generally speaking, ctrl+ any other key which is not A...Z creates issues, depending on the OS and
> the language, and must be avoided.
> (Of course, the user can change this hotkey, if he knows the issue)

This might explain why I cannot get anything useful to work with macro
recording.  Since there is no way to access the macros from a context
menu, they are completely broken on windows.  Features must work across
all supported platforms.  I'm not sure about the behavior on OSX but
platform specific features are a no go in my opinion.

> 
> * Mouse events are not taken in account, and left click is ignored during record.
> 
> * Record is not protected against re-entrance (which can happen by mistake). Try to type <1> during
> recording sequence of macro 1.

I missed that.  This is a serious design flaw.

> 
> To see how a macro can be used, I had to analyze the code.
> 
> A minor other issue is the fact 10 precious hotkeys are not usable for other commands, and this is
> too many keys for me.
> (I am thinking 4 keys could be enough, if Wayne restores the macros code)

There should also be some way to replay the macros via the context menu.

> 
> I can easily understand why Wayne has removed this code, due to these flaws, and the fact the code
> was never maintained.

I'm on the fence now about adding this back.  If no one is going to step
up to fix and/or maintain the macro code, I would rather not restore it.
 I'm not interested in doing that myself.

> 
> 
>>
>> Move group parallel slope tracks (eg data bus):
>> move cursor to first need slope drag track
>> <ctrl+2> - D - <move cursor> - <End>  <ctrl+2>
>> move cursor to next slope track and press only <2>
>>
>> I used macros for leveling length tracks and shove tracks (before CERN release PNS and tuning length)
>> and a more for what.
>>
>>
>>> Вторник, 19 апреля 2016, 22:10 +03:00 от Wayne Stambaugh < stambaughw@xxxxxxxxx >:
>>>
>>> Did record your macro files or did you code them by hand with a text
>>> editor?  The reason I ask is that I have never been able to record a
>>> sensible macro.  I far as I can tell, the macro record feature only
>>> records hot key events which would make it's usefulness somewhat
>>> limited.  I do see the possibility of creating a macro file by hand
>>> using a text editor as useful but this requires an incredible amount of
>>> knowledge of how the hot key event system works which is way beyond the
>>> skill level of your typical user.  I will restore the macro feature for
>>> now but this really needs to be revisited.  Python scripting certainly
>>> provides much more flexibility and power for automating board layout
>>> tasks than the macro recording system.
>>>
>>> On 4/19/2016 2:56 PM, Andrey Fedorushkov wrote:
>>>> Wayne, 
>>>>
>>>> I can not read the newsletter for the past two weeks.
>>>> I did not see the negative reviews about macros.
>>>>
>>>> I use macros to repeat a set of simple operations.
>>>> Moreover, a long time. When there was no opportunity to use python scripts. 
>>>> And transfer macros to python have neither the time nor the possibility.
>>>>
>>>> Here are some examples of my pcb (2008-2015).
>>>> All are made in kicad.
>>>> Without the use of macros is not done :)
>>>>
>>>> At the same time I have been involved in supporting Russian GOST in the kicad (starting with a revno of 62).
>>>> My daughter helped to draw and add Cyrillic characters in vector font 8 years ago (revno 1285). ;)
>>>>
>>>>> Вторник, 19 апреля 2016, 15:14 +03:00 от Wayne Stambaugh < stambaughw@xxxxxxxxx >:
>>>>>
>>>>> Andrey,
>>>>>
>>>>> Users have complained in the past the macro code doesn't do anything
>>>>> useful and I could never get it to anything useful either.  I sent out
>>>>> message over a week ago about getting rid of the macro code.  No one
>>>>> complained including you.  You should have spoke up so I didn't waste my
>>>>> time removing it.  I'm curious exactly what it is you are using them for
>>>>> because I cannot seem to record anything useful.
>>>>>
>>>>> Wayne
>>>>>
>>>>> On 4/19/2016 1:39 AM, AndreyAF wrote:
>>>>>> Wayne!
>>>>>>
>>>>>> Remove macros code?
>>>>>> Why and what for?
>>>>>> I actively use this unique feathure.
> 
> 
> 


Follow ups

References