Hi guys,
Does anyone happen to know how to set the position of the output grip and Name correctly in a custom Component ? Also how to remove the jagged edge if there’s no inputs ? Any help would be much appreciated. I have shared part of the code here
class Custom_Attributes(Grasshopper.Kernel.Attributes.GH_ComponentAttributes):
def __init__(self, component):
self.component = component
def Layout(self):
super(Custom_Attributes, self).Layout()
rec0 = copy.copy(self.Bounds)
rec0.Height += 25
rec0.Width += 80
self.m_innerBounds = rec0
rec1 = copy.copy(rec0)
rec1.Y = rec1.Bottom -20
rec1.X = rec1.Left + 15
rec1.Height = 20
rec1.Width = 100
rec1.Inflate(-2,-2)
self.ButtonBounds = rec1
self.ButtonShine = 1
self.Bounds = rec0
Thanks !