kubaPod / DevTools

DevTools and styles for mathematica developers
28 stars 6 forks source link

Initial Feedback #2

Closed JulianSMoore closed 6 years ago

JulianSMoore commented 6 years ago

Ctrl+1... letter key: breaks if one takes it literally and enters e.g. Shift+N to get indicate capital letter; should handle upper & lower case letters the same?

More generally, I have used the New Function template a couple of times, but it's not to my specific personal prefs and I can't find where the template is - because I'm still ignorant about many internals; however, if an edit command could be added to the menu that would solve it. I did try CodeTemplatesEdit[] but without the example of new function to work from I couldn't do it - and I would be overloading rather than replacing the template if I used the same key, so again direct access to the default templates would be desirable.

Thanks for the opportunity to make a minor contribution - Julian

kubaPod commented 6 years ago

@JulianSMoore I am sorry but could you elaborate on Shift issue? How is Shift involved in entering 1? P.s. this shortcut is motivated by my wish to use {"MenuCommand', "InsertNewGraphics"} :> OpenTemplatesMenu[] in .m notebook's NotebookEvenActions, as opposed to taking care of KeyEvenTranslations.tr. That is easier because I just had to put the code in a stylesheet a nd overload "InsertNewGraphics", a not so commonly used item expecially in .m files.

I agree this 'function' item does not need to be useful for anyone. Maybe it makes sense to make built-in templates part of the user file but it is not how it is done atm. You can inspect them with DevTools`Events`$codeTemplates. Additional information how to write templates is also in Readme.md in repository page. If you have any specific questions let me know. Btw, I will probably add MenuSortingValue option to templates so one can specify that custom templates should appear before/after built-in ones.