diff --git a/OtterGui b/OtterGui index 2c73fd57..4e730a0d 160000 --- a/OtterGui +++ b/OtterGui @@ -1 +1 @@ -Subproject commit 2c73fd57bf53fc3c9f390db0acc9e176607c2dbc +Subproject commit 4e730a0d5a86a9819bcea0b766134c02f35ac27e diff --git a/Penumbra/UI/Classes/ItemSwapWindow.cs b/Penumbra/UI/Classes/ItemSwapWindow.cs index cbef6c19..8215bcc7 100644 --- a/Penumbra/UI/Classes/ItemSwapWindow.cs +++ b/Penumbra/UI/Classes/ItemSwapWindow.cs @@ -399,7 +399,7 @@ public class ItemSwapWindow : IDisposable ImGui.AlignTextToFramePadding(); ImGui.TextUnformatted( text1 ); ImGui.TableNextColumn(); - _dirty |= sourceSelector.Draw( "##itemSource", sourceSelector.CurrentSelection.Item1 ?? string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); + _dirty |= sourceSelector.Draw( "##itemSource", sourceSelector.CurrentSelection.Item1 ?? string.Empty, string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); if( type == SwapType.Ring ) { @@ -411,7 +411,7 @@ public class ItemSwapWindow : IDisposable ImGui.AlignTextToFramePadding(); ImGui.TextUnformatted( text2 ); ImGui.TableNextColumn(); - _dirty |= targetSelector.Draw( "##itemTarget", targetSelector.CurrentSelection.Item1 ?? string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); + _dirty |= targetSelector.Draw( "##itemTarget", targetSelector.CurrentSelection.Item1 ?? string.Empty, string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); if( type == SwapType.Ring ) { ImGui.SameLine(); @@ -503,7 +503,7 @@ public class ItemSwapWindow : IDisposable ImGui.AlignTextToFramePadding(); ImGui.TextUnformatted( "Select the weapon or tool you want" ); ImGui.TableNextColumn(); - if( _slotSelector.Draw( "##weaponSlot", _slotSelector.CurrentSelection.ToName(), InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ) ) + if( _slotSelector.Draw( "##weaponSlot", _slotSelector.CurrentSelection.ToName(), string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ) ) { _dirty = true; _weaponSource = new ItemSelector( _slotSelector.CurrentSelection ); @@ -520,13 +520,13 @@ public class ItemSwapWindow : IDisposable ImGui.AlignTextToFramePadding(); ImGui.TextUnformatted( "and put this variant of it" ); ImGui.TableNextColumn(); - _dirty |= _weaponSource.Draw( "##weaponSource", _weaponSource.CurrentSelection.Item1 ?? string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); + _dirty |= _weaponSource.Draw( "##weaponSource", _weaponSource.CurrentSelection.Item1 ?? string.Empty, string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); ImGui.TableNextColumn(); ImGui.AlignTextToFramePadding(); ImGui.TextUnformatted( "onto this one" ); ImGui.TableNextColumn(); - _dirty |= _weaponTarget.Draw( "##weaponTarget", _weaponTarget.CurrentSelection.Item1 ?? string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); + _dirty |= _weaponTarget.Draw( "##weaponTarget", _weaponTarget.CurrentSelection.Item1 ?? string.Empty, string.Empty, InputWidth * 2, ImGui.GetTextLineHeightWithSpacing() ); } private const float InputWidth = 120; diff --git a/Penumbra/UI/Classes/ModEditWindow.Materials.cs b/Penumbra/UI/Classes/ModEditWindow.Materials.cs index 54330ecb..400a7f47 100644 --- a/Penumbra/UI/Classes/ModEditWindow.Materials.cs +++ b/Penumbra/UI/Classes/ModEditWindow.Materials.cs @@ -268,7 +268,7 @@ public partial class ModEditWindow ImGui.SameLine(); var label = dyeId == 0 ? "Preview Dye###previewDye" : $"{name} (Preview)###previewDye"; - Penumbra.StainManager.StainCombo.Draw( label, dyeColor, true ); + Penumbra.StainManager.StainCombo.Draw( label, dyeColor, string.Empty, true ); return false; } @@ -508,7 +508,7 @@ public partial class ModEditWindow ImGui.TableNextColumn(); if( hasDye ) { - if( Penumbra.StainManager.TemplateCombo.Draw( "##dyeTemplate", dye.Template.ToString(), intSize + if( Penumbra.StainManager.TemplateCombo.Draw( "##dyeTemplate", dye.Template.ToString(), string.Empty, intSize + ImGui.GetStyle().ScrollbarSize / 2, ImGui.GetTextLineHeightWithSpacing(), ImGuiComboFlags.NoArrowButton ) ) { file.ColorDyeSets[ colorSetIdx ].Rows[ rowIdx ].Template = Penumbra.StainManager.TemplateCombo.CurrentSelection; diff --git a/Penumbra/UI/ConfigWindow.CollectionsTab.Individual.cs b/Penumbra/UI/ConfigWindow.CollectionsTab.Individual.cs index 992a0d80..2e3a7194 100644 --- a/Penumbra/UI/ConfigWindow.CollectionsTab.Individual.cs +++ b/Penumbra/UI/ConfigWindow.CollectionsTab.Individual.cs @@ -33,7 +33,7 @@ public partial class ConfigWindow => obj.Value; public bool Draw( float width ) - => Draw( "##worldCombo", CurrentSelection.Value, width, ImGui.GetTextLineHeightWithSpacing() ); + => Draw( "##worldCombo", CurrentSelection.Value, string.Empty, width, ImGui.GetTextLineHeightWithSpacing() ); } private sealed class NpcCombo : FilterComboCache< (string Name, uint[] Ids) > @@ -60,7 +60,7 @@ public partial class ConfigWindow } public bool Draw( float width ) - => Draw( _label, CurrentSelection.Name, width, ImGui.GetTextLineHeightWithSpacing() ); + => Draw( _label, CurrentSelection.Name, string.Empty, width, ImGui.GetTextLineHeightWithSpacing() ); } diff --git a/Penumbra/UI/ConfigWindow.CollectionsTab.cs b/Penumbra/UI/ConfigWindow.CollectionsTab.cs index 979ada02..f356f983 100644 --- a/Penumbra/UI/ConfigWindow.CollectionsTab.cs +++ b/Penumbra/UI/ConfigWindow.CollectionsTab.cs @@ -167,7 +167,7 @@ public partial class ConfigWindow public void Draw() { var preview = CurrentIdx >= 0 ? Items[ CurrentIdx ].Item2 : string.Empty; - Draw( _label, preview, ref CurrentIdx, _unscaledWidth * ImGuiHelpers.GlobalScale, ImGui.GetTextLineHeightWithSpacing() ); + Draw( _label, preview, string.Empty, ref CurrentIdx, _unscaledWidth * ImGuiHelpers.GlobalScale, ImGui.GetTextLineHeightWithSpacing() ); } protected override string ToString( (CollectionType, string, string) obj ) diff --git a/Penumbra/UI/ConfigWindow.Misc.cs b/Penumbra/UI/ConfigWindow.Misc.cs index ed180fd2..b683b75e 100644 --- a/Penumbra/UI/ConfigWindow.Misc.cs +++ b/Penumbra/UI/ConfigWindow.Misc.cs @@ -122,7 +122,7 @@ public partial class ConfigWindow public void Draw( string label, float width, int individualIdx ) { var (_, collection) = Penumbra.CollectionManager.Individuals[ individualIdx ]; - if( Draw( label, collection.Name, width, ImGui.GetTextLineHeightWithSpacing() ) && CurrentSelection != null ) + if( Draw( label, collection.Name, string.Empty, width, ImGui.GetTextLineHeightWithSpacing() ) && CurrentSelection != null ) { Penumbra.CollectionManager.SetCollection( CurrentSelection, CollectionType.Individual, individualIdx ); } @@ -131,7 +131,7 @@ public partial class ConfigWindow public void Draw( string label, float width, CollectionType type ) { var current = Penumbra.CollectionManager.ByType( type, ActorIdentifier.Invalid ); - if( Draw( label, current?.Name ?? string.Empty, width, ImGui.GetTextLineHeightWithSpacing() ) && CurrentSelection != null ) + if( Draw( label, current?.Name ?? string.Empty, string.Empty, width, ImGui.GetTextLineHeightWithSpacing() ) && CurrentSelection != null ) { Penumbra.CollectionManager.SetCollection( CurrentSelection, type ); }