Skip to main content
added 135 characters in body
Source Link
batFINGER
  • 85.2k
  • 10
  • 114
  • 244

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

To display the property in the UI set it to True. The default is slider = False

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure to set the minimum and maximum of the property, if unset the default values are +/- the maximum possible value on your system and as a result the slider will sit around the middle and be somewhat meaningless.

Tip: RightEdit Prefs > Interface > Display and enable "Developer Extras" will enable you to right click over any (most) UI element and view source to seeopen the code behind the UI into the text editor.

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

To display the property in the UI set it to True. The default is slider = False

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure to set the minimum and maximum of the property, if unset the default values are +/- the maximum possible value on your system and as a result the slider will sit around the middle and be somewhat meaningless.

Tip: Right click and view source to see the code behind the UI.

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

To display the property in the UI set it to True. The default is slider = False

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure to set the minimum and maximum of the property, if unset the default values are +/- the maximum possible value on your system and as a result the slider will sit around the middle and be somewhat meaningless.

Tip: Edit Prefs > Interface > Display and enable "Developer Extras" will enable you to right click over any (most) UI element and view source to open the code behind the UI into the text editor.

added 58 characters in body
Source Link
batFINGER
  • 85.2k
  • 10
  • 114
  • 244

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

Most notably for making a sliderTo display the property in the UI set it to True. The default is slider = False

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure youto set the minimum and maximum of the property, sinceif unset the default values are +/- the maximum possible value on your system, otherwise and as a result the slider will sit around the middle and be somewhat meaninglessand be somewhat meaningless.

Tip: If you see some UI that you want to copy, rightRight click and view source to see the code behind the UI.

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

Most notably for making a slider

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure you set the minimum and maximum of the property, since the default values are +/- the maximum possible value on your system, otherwise the slider will sit around the middle and be somewhat meaningless.

Tip: If you see some UI that you want to copy, right click and view source.

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

To display the property in the UI set it to True. The default is slider = False

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure to set the minimum and maximum of the property, if unset the default values are +/- the maximum possible value on your system and as a result the slider will sit around the middle and be somewhat meaningless.

Tip: Right click and view source to see the code behind the UI.

added 220 characters in body
Source Link
batFINGER
  • 85.2k
  • 10
  • 114
  • 244

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

Most notably for making a slider

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure you set the minimum and maximum of the property, since the default values are +/- the maximum possible value on your system, otherwise the slider will sit around the middle and be somewhat meaningless.

Tip: If you see some UI that you want to copy, right click and view source.

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

Most notably for making a slider

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

If you see some UI that you want to copy, right click and view source.

Set slider property to True

Consult the docs on UILayout.prop,

prop(data, property, text="", text_ctxt="", translate=True, icon='NONE', expand=False, slider=False, toggle=False, icon_only=False, event=False, full_event=False, emboss=True, index=-1, icon_value=0)

Most notably for making a slider

slider (boolean, (optional)) – Use slider widget for numeric values

Sample code

def draw(self, context):
    self.layout(context.object, "prop", slider=True)

Make sure you set the minimum and maximum of the property, since the default values are +/- the maximum possible value on your system, otherwise the slider will sit around the middle and be somewhat meaningless.

Tip: If you see some UI that you want to copy, right click and view source.

Source Link
batFINGER
  • 85.2k
  • 10
  • 114
  • 244
Loading