Skip to content

Commit 39223a2

Browse files
committed
add HideWallLaneWhenEnablePlayField
1 parent a9f5154 commit 39223a2

11 files changed

Lines changed: 386 additions & 329 deletions

File tree

OngekiFumenEditor/App.config

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,6 +233,9 @@
233233
<setting name="RenderTargetOrderVisibleMap" serializeAs="String">
234234
<value />
235235
</setting>
236+
<setting name="HideWallLaneWhenEnablePlayField" serializeAs="String">
237+
<value>False</value>
238+
</setting>
236239
</OngekiFumenEditor.Properties.EditorGlobalSetting>
237240
<OngekiFumenEditor.Properties.AudioPlayerToolViewerSetting>
238241
<setting name="ResampleSize" serializeAs="String">

OngekiFumenEditor/Kernel/SettingPages/FumenVisualEditor/Views/FumenVisualEditorGlobalSettingView.xaml

Lines changed: 29 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -137,17 +137,24 @@
137137
</StackPanel>
138138
<GroupBox Margin="5,0,5,5" Header="{markup:Translate [PreviewMode]}">
139139
<StackPanel Margin="10">
140-
<WrapPanel Orientation="Horizontal">
141-
<TextBlock VerticalAlignment="Center" Text="{markup:Translate [BellBulletCountOverLimit_Part1]}" TextWrapping="WrapWithOverflow" />
140+
<WrapPanel Orientation="Horizontal">
141+
<TextBlock
142+
VerticalAlignment="Center"
143+
Text="{markup:Translate [BellBulletCountOverLimit_Part1]}"
144+
TextWrapping="WrapWithOverflow" />
142145
<StackPanel Orientation="Horizontal">
143146
<TextBox
144147
Width="50"
145148
Margin="5,0,2,0"
146149
Text="{Binding Setting.ParallelCountLimit}">
147150
</TextBox>
148-
<TextBlock Text="{markup:Translate [BellBulletCountOverLimit_Sep]}"></TextBlock>
151+
<TextBlock Text="{markup:Translate [BellBulletCountOverLimit_Sep]}">
152+
</TextBlock>
149153
</StackPanel>
150-
<TextBlock VerticalAlignment="Center" Text="{markup:Translate [BellBulletCountOverLimit_Part2]}" TextWrapping="WrapWithOverflow" />
154+
<TextBlock
155+
VerticalAlignment="Center"
156+
Text="{markup:Translate [BellBulletCountOverLimit_Part2]}"
157+
TextWrapping="WrapWithOverflow" />
151158
</WrapPanel>
152159
<StackPanel Margin="0,10,0,5" Orientation="Horizontal">
153160
<TextBlock VerticalAlignment="Center" Text="{markup:Translate [BackgroundColor]}" />
@@ -166,22 +173,24 @@
166173
<CheckBox IsChecked="{Binding Setting.EnablePlayFieldDrawing}">
167174
<TextBlock Text="{markup:Translate [EnablePlayFieldDrawing]}" />
168175
</CheckBox>
169-
<StackPanel
170-
Margin="0,5,0,5"
171-
IsEnabled="{Binding Setting.EnablePlayFieldDrawing}"
172-
Orientation="Horizontal">
173-
<TextBlock VerticalAlignment="Center" Text="{markup:Translate [PlayFieldForegroundColor]}" />
174-
<Border
175-
Width="60"
176-
Height="18"
177-
Margin="10,0"
178-
cal:Message.Attach="[Event MouseDown] = [Action OnSelectForegroundColor($executionContext)]"
179-
Background="{Binding Setting.PlayFieldForegroundColor, Converter={StaticResource IntToSolidBrush}}"
180-
BorderBrush="{Binding Setting.PlayFieldForegroundColor, Converter={StaticResource IntToSolidBrush}, ConverterParameter=True}"
181-
BorderThickness="1"
182-
CornerRadius="7"
183-
Cursor="Hand">
184-
</Border>
176+
<StackPanel Margin="0,5,0,5" IsEnabled="{Binding Setting.EnablePlayFieldDrawing}">
177+
<StackPanel Orientation="Horizontal">
178+
<TextBlock VerticalAlignment="Center" Text="{markup:Translate [PlayFieldForegroundColor]}" />
179+
<Border
180+
Width="60"
181+
Height="18"
182+
Margin="10,0"
183+
cal:Message.Attach="[Event MouseDown] = [Action OnSelectForegroundColor($executionContext)]"
184+
Background="{Binding Setting.PlayFieldForegroundColor, Converter={StaticResource IntToSolidBrush}}"
185+
BorderBrush="{Binding Setting.PlayFieldForegroundColor, Converter={StaticResource IntToSolidBrush}, ConverterParameter=True}"
186+
BorderThickness="1"
187+
CornerRadius="7"
188+
Cursor="Hand">
189+
</Border>
190+
</StackPanel>
191+
<CheckBox Margin="0,5,0,0" IsChecked="{Binding Setting.HideWallLaneWhenEnablePlayField}">
192+
<TextBlock Text="{markup:Translate [HideWallLaneWhenEnablePlayField]}" />
193+
</CheckBox>
185194
</StackPanel>
186195
<CheckBox IsChecked="{Binding Setting.EnableShowPlayerLocation}">
187196
<TextBlock Text="{markup:Translate [EnableShowPlayerLocation]}" TextWrapping="WrapWithOverflow" />

OngekiFumenEditor/Modules/FumenVisualEditor/Graphics/Drawing/TargetImpl/OngekiObjects/Lane/WallLaneDrawTarget.cs

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
using OngekiFumenEditor.Base.OngekiObjects.ConnectableObject;
2+
using OngekiFumenEditor.Base.OngekiObjects.Lane.Base;
23
using System.Collections.Generic;
34
using System.ComponentModel.Composition;
45
using System.Numerics;
@@ -13,7 +14,14 @@ internal abstract class WallLaneDrawTarget : LaneDrawingTargetBase
1314
public abstract Vector4 WallLaneColor { get; }
1415
public override int LineWidth => 6;
1516
public override Vector4 GetLanePointColor(ConnectableObjectBase obj) => WallLaneColor;
16-
}
17+
18+
public override void DrawBatch(IFumenEditorDrawingContext target, IEnumerable<LaneStartBase> starts)
19+
{
20+
if (target.Editor.HideWallLaneWhenEnablePlayField)
21+
return;
22+
base.DrawBatch(target, starts);
23+
}
24+
}
1725

1826
[Export(typeof(IFumenEditorDrawingTarget))]
1927
internal class WallLeftLaneDrawTarget : WallLaneDrawTarget

0 commit comments

Comments
 (0)