Inkscape.org
Beyond the Basics Resizing/Scale Angled path
  1. #1
    Louis Peloille Louis Peloille @wowmoment

    Hello,

    I have a drawing made more 3mm thick plywood. The latest batch I got is 3.4mm. There're slot within the path sized for 3mm The horizontal or vertical slot have been resized without any issues but I'm struggling (I've no clue how...) to resize the angled ones, as per the picture.

    Please, I would appreciate any help to achieve this.

    Thank you! :)

    Inkscape
  2. #2
    Polygon Polygon @Polygon🌶

    I guess in this case I´d delete the 3mm version and draw a 3,4mm broad stroke - align the angle and placement - go Path->Stroke to Path and if you need it as a hole select shape and converted stroke and go Path->Difference.

  3. #3
    Louis Peloille Louis Peloille @wowmoment

    Thank for suggestion!

    I found a workaround by calculating X Delta and Y Delta based on the angle given by the measuring tool (snapping mode on). A bit time consuming but it worked and I could apply the X Delta and Y Delta to a group of nodes that were moving in the same direction, positive or negative. I don't know if it can be implemented into a plugin, I'll see if I have time to do so...:)

    Script Python

    # Re-importing math for trigonometric calculations
    import math

    # Redefining constants for the new input
    initial_length = 3.00  # in mm
    desired_length = 3.40  # in mm
    length_difference = desired_length - initial_length

    # New starting point and angle provided
    X_start = 65.115  # in mm
    Y_start = 21.946  # in mm
    angle_degrees_provided = -54  # angle in degrees

    # Convert the provided angle to radians
    angle_radians_provided = math.radians(angle_degrees_provided)

    # Compute the changes in X and Y using the new angle
    delta_x_provided = length_difference * math.cos(angle_radians_provided)
    delta_y_provided = length_difference * math.sin(angle_radians_provided)

    delta_x_provided, delta_y_provided