WeightPainterPanel.uxml 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. <?xml version="1.0" encoding="utf-8"?>
  2. <UXML xmlns:ui="UnityEngine.UIElements" xmlns:eui="UnityEditor.UIElements" xmlns:aui="UnityEditor.U2D.Animation">
  3. <aui:WeightPainterPanel name="WeightPainterPanel" text="Weight Painter" picking-mode="Ignore">
  4. <ui:PopupWindow text="Weight Painter">
  5. <ui:VisualElement name ="BrushModeField" class="form-row">
  6. <ui:VisualElement class="form-popup" name="Mode" />
  7. <!-- No support for Enums outside of UnityEditor -->
  8. <!-- <eui:EnumField name="ModeField" type="WeightEditorMode" /> -->
  9. </ui:VisualElement>
  10. <ui:VisualElement name="Bone" class="form-row">
  11. <ui:VisualElement class="form-popup" name="BoneEnumPopup" />
  12. <!-- No factory method for PopupField here -->
  13. </ui:VisualElement>
  14. <ui:VisualElement class="form-row">
  15. <ui:Toggle name="NormalizeToggle" class="form-toggle" value="true" tooltip="Normalize weights after each edit" label="Normalize" />
  16. </ui:VisualElement>
  17. <ui:VisualElement name="Size" class="form-row">
  18. <eui:IntegerField name="SizeField" class="form-integerfield" value="25" label="Size" tooltip ="Brush size"/>
  19. </ui:VisualElement>
  20. <ui:VisualElement name="Amount" class="form-row">
  21. <ui:Label name="AmountLabel" text="Amount" tooltip ="Weight amount"/>
  22. <ui:VisualElement class="form-editor">
  23. <ui:Slider name="AmountSlider" direction="Horizontal" low-value="-1" high-value="1" />
  24. <eui:FloatField name="AmountField" class="slider-field" value="0" />
  25. </ui:VisualElement>
  26. </ui:VisualElement>
  27. <ui:VisualElement name="divider" />
  28. <aui:WeightInspectorIMGUIPanel name ="WeightsInspector" />
  29. <ui:VisualElement name="Hardness" class="form-row">
  30. <ui:Label name="HardnessLabel" text="Hardness" tooltip ="Brush hardness"/>
  31. <ui:VisualElement class="form-editor">
  32. <ui:Slider name="HardnessSlider" direction="Horizontal" low-value="1" high-value="100" />
  33. <eui:IntegerField name="HardnessField" class="slider-field" value="1" />
  34. </ui:VisualElement>
  35. </ui:VisualElement>
  36. <ui:VisualElement name="Step" class="form-row">
  37. <ui:Label name="StepLabel" text="Step" tooltip ="Brush step size"/>
  38. <ui:VisualElement class="form-editor">
  39. <ui:Slider name="StepSlider" direction="Horizontal" low-value="1" high-value="100" />
  40. <eui:IntegerField name="StepField" class="slider-field" value="1" />
  41. </ui:VisualElement>
  42. </ui:VisualElement>
  43. </ui:PopupWindow>
  44. </aui:WeightPainterPanel>
  45. </UXML>