Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 05/06/2021 in all areas

  1. Create this macro: Command name Osnapcoord Description Toggle OSNAPCOORD overrides between "Keyboard entry except in scripts" & "Osnap settings". Macro ^P'setvar;osnapcoord;$M=$(if,$(and,2,$(getvar,osnapcoord)),0,2) ^P Element ID Osnapcoord Add the macro to your Object Snap Cursor Menu then add: Display Name $(if,$(and,2,$(getvar,osnapcoord)),"Zoom Osnap","Keyboard entry except scripts") which goes just above: Command name Osnapcoord I'd recommend resetting OSNAPCOORD to 2 in acaddoc.lsp to avoid issues should you forget to toggle it back: (if (/= (getvar 'osnapcoord) 2)(progn(setvar 'osnapcoord 2)(princ "\nKeyboard entry overrides object snap settings. OSNAPCOORD")))
    1 point
  2. I always admire people who puts in the effort to learn and understand. And I will always help those type of people. Those are the filters for the selection set. You can look up for the codes through here. Now, let's take a circle (for example), and use the entget function on it to retrieve its properties. As an example, you can inspect this, and see the result returned: entget retrieves the properties of the object that was selected. This is an example. Now in the ssget function, you can include such filters in (except enames), so that any entities to be selected should have the properties that satisfies the criteria set within the ssget filters. Therefore, (0 . "CIRCLE") simply means that only circles can be selected. -4 stands for a conditional operator (such and AND, OR, *, etc...). And in the case of a circle, this will be the radius. As a first year of learning LISP, these codes may appear a bit confusing to you (because it was way too confusing for me). You can include as many filters into ssget as you want. You can view more here.
    1 point
  3. The "O" in zoom options is for OBJECT. Use ZOOM then O then select the object to zoom to. The viewport will then zoom and window itself centered on the object selected. There is no need to change any setting or variable. You will then have to click the object again to get the grips to show if you want to snap somewhere on the object, but it is still easier than resetting a critical variable each time.
    1 point
  4. SET FILEDIA TO 0 MAYBE? --EDIT-- What is the warning? this suppresses the read only https://www.cadforum.cz/en/qaID.asp?tip=5666
    1 point
  5. I never knew that worked for Zoom before! Quick lisp that allows you to Zoom Window using your Osnap settings by setting and resetting the OSNAPCOORD value to preserve "Keyboard Entry". ; https://www.cadtutor.net/forum/topic/72916-snapping-to-objects-when-zooming-in-viewport/?tab=comments#comment-580609 ; Zoom Window using Osnap settings by Tom Beauford (defun c:ZSnap ( / *error* osnapcoord) (defun *Error* (msg) ; embedded defun (setvar 'osnapcoord osnapcoord) (if (/= s "Function cancelled") (princ (strcat "\nError: " msg)) ) (princ) ) (setvar "cmdecho" 0) (setq osnapcoord (getvar 'osnapcoord)) (setvar 'osnapcoord 0) (command-s "zoom" PAUSE) (while (= 1 (logand 1 (getvar "cmdactive"))) PAUSE ) ;null responce exits zoom (setvar 'osnapcoord osnapcoord) ;reset osnapcoord (princ) ) While command-s is needed for newer versions you will need to change (command-s "zoom" PAUSE) to (command "zoom" PAUSE) for older versions like 2013. Save it as "ZSnap.lsp" in a support folder. Load and run by entering (load "ZSnap.lsp") then ZSnap at the command line. You could alse add ^P(or C:ZSnap (load "Leader.lsp"));ZSnap as a command macro for easy access.
    1 point
  6. Make a block of it. Then you can scale it in X or Y direction in properties.
    1 point
  7. On the bus, or off the bus. You can't prioritize them BOTH.
    1 point
  8. Dark Mode is much better for me. Thanks!
    1 point
  9. this is the dark theme layout in the dark theme firefox with dark theme colors in Autocad. My vampire eyes can be at ease.
    1 point
  10. My eyes feel better already, Thank you!
    1 point
  11. A couple of subtle changes. Joa0009 do you mean to hatch with solid ? (defun C:FOO (/ SS col rad) (setq rad (cdr (assoc 40 (entget (car (entsel "Pick a circle ")))))) (setq col (getint "\nEnter color number ")) (if (setq SS (ssget "_X" (list (cons 0 "CIRCLE") (cons -4 "=")(cons 40 rad)))) (vl-cmdf "_Chprop" SS "" "C" col "") ;change Color to what you want ) )
    1 point
  12. Don't know what you mean by window Viewport? This will select everything in the drawing and filter down to circles that match the radi value you put. more info here. (defun C:FOO (/ SS ) (if (setq SS (ssget "_X" '((0 . "CIRCLE") (-4 . "=") (40 . radi)))) ;change radi to the radius you want (vl-cmdf "_Chprop" SS "" "C" "COLOR" "") ;change Color to what you want ) )
    1 point
  13. Were still waiting for jao009, maybe a bit more. (setq *circle_color* (acad_colordlg 2) *circle_radius* (cdr (assoc 40 (entget (car (entsel "\nSelect a circle"))))) *circle_acdoc* (vla-get-ActiveDocument (vlax-get-acad-object)) )
    0 points
×
×
  • Create New...