Saturday, December 2, 2023
Home3D ModelingSketchup Professional 2023 Customized Trays Have Parts Blacked Out - Professional

Sketchup Professional 2023 Customized Trays Have Parts Blacked Out – Professional


@OldCoot – The AHK script is under. Take cautious notice of the feedback. Numerous that is arduous coded to work with my setup, so you might have to make changes. Use at your personal threat.

; AlignTrays – Align Trays
; I’ve to run in administrator mode for this to work with Sketchup 2023
;
; That is arrange for 3 screens.
; My show decision is 2560×1440
; You could have to regulate defW/defH variables under to your display
; This script additionally assumes the middle show is the first monitor,
; with the left monitor having unfavourable coordinates, the middle monitor beginning at 0, 0,
; and the correct monitor beginning on the show width coordinate.

#NoEnv ; Really helpful for efficiency and compatibility with future AutoHotkey releases.
#Warn ; Allow warnings to help with detecting frequent errors.
#Singleinstance drive
;SendMode Enter ; Really helpful for brand new scripts as a consequence of its superior velocity and reliability.
;SetWorkingDir %A_ScriptDir% ; Ensures a constant beginning listing.

;————–CRITICAL INFO——————-
;I’m working with the next custom-made SketchUp trays:
;T1 (SU Tray 1)
;T2 (SU Tray 2)
;T3 (SU Tray 3)
;Mannequin Information (SU mannequin data)
;Profile Dialog (profile builder dialog)

;set AHK definitions
;Use Alt+F9 to align left, Alt+F10 to align heart, Alt+F11 to align proper
!F9::AlignTrays(1)
!F10::AlignTrays(2)
!F11::AlignTrays(3)

AlignTrays(mon)
{
; Get the system settings for obtainable monitor area
SysGet, m, Monitor, %mon%
defW := 447 ; default width of the trays, regulate as wanted to your monitor decision
defT := 30 ; This may be set to zero, however I want an offset on the prime as a result of I’ve WinStep loaded and it takes up some prime area.
defH := 1100 ; default top of trays, regulate to your monitor decision
if (mon = 1)
{
x1 := (mRight – defW)
}
else
{
x1 := (mLeft)
}
; set the the place of T1, every little thing else aligns with it.
; the +10 was added right here to resize the window to work round a SketchUp bug.
; the subsequent line could be eliminated as soon as SU fixes the bug
WinMove, T1, %x1%, %defT%, defW+10, 1100 ; take away when bug is fastened
WinMove, T1, %x1%, %defT%, defW, 1100
WinGetPos, x, y, w, h, T1
; some changes to get coordinates to align.
; the sketchup trays don’t report window sizing the identical as different home windows, so needed to regulate
if (mon = 1)
{
x1 := x – defW – 1
}
else
{
x1 := x + defW + 1
}
y := defT + 1
; transfer and measurement tray 2 equal to tray 1
; the +10 was added right here to resize the window to work round a SketchUp bug.
; the subsequent line could be eliminated as soon as SU fixes the bug
WinMove, T2, x1, y, defW+10, h ; take away when bug is fastened
WinMove, T2, x1, y, defW, h
if (mon = 1)
{
x1 := x1 – (defW – 1)
}
else
{
x1 := x1 + (defW + 1)
}
; transfer and measurement tray 3 equal to 1 and a pair of
; the +10 was added right here to resize the window to work round a SketchUp bug.
; the subsequent line could be eliminated as soon as SU fixes the bug
WinMove, T3, x1, y, defW+10, h ; take away when bug is fastened
WinMove, T3, x1, y, defW, h
; transfer mannequin data to new coordinates
if (mon = 1)
{
WinGetPos, x, y, w, h, Mannequin Information
x1 := (x1 – w + 6)
}
else
{
WinGetPos, x, y, w, h, T3
x1 := (x1 + w – 6)
}
y := defT – 1
WinMove, Mannequin Information, x1, defT
WinGetPos, x, y, w, h, Mannequin Information
if WinExist(“Profile Dialog”)
{
; regulate coordinates for profile builder
y := h + 24
h := defH – h + 12
; transfer profile builder dialog below mannequin data
WinMove, Profile Dialog, x, y, w, h
}
}

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments