Author Topic: Caps Lock  (Read 18496 times)

0 Members and 1 Guest are viewing this topic.

BlackBox

  • King Gator
  • Posts: 3770
Re: Caps Lock
« Reply #30 on: April 12, 2012, 10:01:22 AM »
I'm glad you're able to use this, Tim.

FWIW - Rather than calling (car Plist) for each expression in the Or Statements for your callback(s), consider using vl-Postion instead:

Code - Auto/Visual Lisp: [Select]
  1.       (car Plist)
  2.       '("ATTEDIT" "DDEDIT" "DTEXT" "MTEXT" "TEXT" "TEXTEDIT"))
  3.   (CAPSLOCK ;| T/Nil |;)
  4.   )
  5.  
« Last Edit: April 12, 2012, 10:30:48 AM by RenderMan »
"How we think determines what we do, and what we do determines what we get."

TimSpangler

  • Water Moccasin
  • Posts: 2010
  • CAD Naked!!
Re: Caps Lock
« Reply #31 on: April 12, 2012, 10:20:06 AM »
Great suggestion, and a bit cleaner
ACA 2015 - Windows 7 Pro
All Comments and Content by TimSpangler, Copyright © 2016

ronjonp

  • Needs a day job
  • Posts: 7527
Re: Caps Lock
« Reply #32 on: April 12, 2012, 10:51:13 AM »
I'd use wcmatch like so:  :-)

Code - Auto/Visual Lisp: [Select]
  1. (if (wcmatch (car plist) "*TEXT*,*EDIT")
  2.   (capslock ;| T/Nil |;)
  3. )

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

alanjt

  • Needs a day job
  • Posts: 5352
  • Standby for witty remark...
Re: Caps Lock
« Reply #33 on: April 12, 2012, 10:53:31 AM »
I'd use wcmatch like so:  :-)

Code - Auto/Visual Lisp: [Select]
  1. (if (wcmatch (car plist) "*TEXT*,*EDIT,MLEADER")
  2.   (capslock ;| T/Nil |;)
  3. )
added one
Civil 3D 2019 ~ Windohz 7 64bit
Dropbox

TimSpangler

  • Water Moccasin
  • Posts: 2010
  • CAD Naked!!
Re: Caps Lock
« Reply #34 on: April 12, 2012, 10:58:13 AM »
I updated the attached reactor code to add a few more and incorporated the wcmatch.
ACA 2015 - Windows 7 Pro
All Comments and Content by TimSpangler, Copyright © 2016

TimSpangler

  • Water Moccasin
  • Posts: 2010
  • CAD Naked!!
Re: Caps Lock
« Reply #35 on: April 20, 2012, 10:07:06 AM »
Well I've been using this for over a week (with the reactor) and I have to say it is fabulous.  I never have to touch the caps lock key. No more shouting in my emails.

Thanks to all who were involved, great group effort.
ACA 2015 - Windows 7 Pro
All Comments and Content by TimSpangler, Copyright © 2016

BlackBox

  • King Gator
  • Posts: 3770
Re: Caps Lock
« Reply #36 on: April 20, 2012, 10:23:02 AM »
I'm glad you're finding this tool useful, Tim - I am also happy with the result of this little collaboration.  :kewl:

I have also been using this in a reactor, and have only come across one situation where behavior is not what I expected... when editing a table. For example, double clicking a cell to enter text, the capslock is turned on correctly. It is when I Tab into the next cell.

I added a (Print (car cmd)) call at the top of my CommandWillStart, and CommandEnded Callback functions, and it appears that Tabbing into the next cell cycles the TableEdit Command. I've had different results when using Tab, and the arrow keys.

... Just thought I'd share.
"How we think determines what we do, and what we do determines what we get."

BlackBox

  • King Gator
  • Posts: 3770
Re: Caps Lock
« Reply #37 on: August 17, 2012, 10:24:33 AM »
Code updated here... Summary of changes:

** Update - 2012-08-17

Additional 'LispException' Classes added for completeness (thanks Gile!), and attached the following assembly versions:

LispKeys2010.dll (compiled to .NET 3.5 for 2010 database format)
LispKeys2013.dll (compiled to .NET 4.0 for 2013 database format)

... Next enhancement will streamline, adding Methods (sub-functions) to remove duplicate code.
"How we think determines what we do, and what we do determines what we get."