컨텍스트 사용량 링 정렬 회귀 수정
원인: 하단 컨텍스트 사용량 트랙은 22x22 원형인데 arc는 center=15, radius=11 하드코딩으로 더 크게 그려져 오른쪽으로 밀려 보였습니다. 수정: TokenUsageTrack과 TokenUsageArc를 같은 크기와 가운데 정렬로 맞추고, 실제 트랙 지름과 스트로크 두께를 기준으로 중심점·반지름을 계산하는 helper를 추가했습니다. 크기 변경 시에도 arc가 다시 그려지도록 캐시 조건도 보강했습니다. 검증: dotnet build src/AxCopilot/AxCopilot.csproj -c Release -v minimal -p:OutputPath=bin\verify_token_ring_alignment\ -p:IntermediateOutputPath=obj\verify_token_ring_alignment\ (경고 0 / 오류 0), dotnet test src/AxCopilot.Tests/AxCopilot.Tests.csproj -c Release -v minimal --filter ChatWindowSlashPolicyTests -p:OutputPath=bin\verify_token_ring_alignment_tests\ -p:IntermediateOutputPath=obj\verify_token_ring_alignment_tests\ (통과 53)
This commit is contained in:
@@ -2673,7 +2673,8 @@
|
||||
MouseLeave="TokenUsageCard_MouseLeave">
|
||||
<Grid Width="28" Height="28">
|
||||
<!-- Ring track (subtle background ring) -->
|
||||
<Ellipse Width="22" Height="22"
|
||||
<Ellipse x:Name="TokenUsageTrack"
|
||||
Width="22" Height="22"
|
||||
Stroke="{DynamicResource BorderColor}"
|
||||
StrokeThickness="2"
|
||||
Opacity="0.45"
|
||||
@@ -2681,10 +2682,16 @@
|
||||
VerticalAlignment="Center"/>
|
||||
<!-- Usage arc (progress) -->
|
||||
<Path x:Name="TokenUsageArc"
|
||||
Width="22"
|
||||
Height="22"
|
||||
Stroke="{DynamicResource AccentColor}"
|
||||
StrokeThickness="2"
|
||||
StrokeStartLineCap="Round"
|
||||
StrokeEndLineCap="Round"/>
|
||||
StrokeEndLineCap="Round"
|
||||
Stretch="None"
|
||||
SnapsToDevicePixels="True"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"/>
|
||||
<!-- Hidden data elements (referenced in code) -->
|
||||
<StackPanel Visibility="Collapsed">
|
||||
<TextBlock x:Name="TokenUsagePercentText"
|
||||
|
||||
Reference in New Issue
Block a user