fix: fix render geoetry issue and color picker scroll issue

This commit is contained in:
2025-09-08 16:38:57 +08:00
parent 082ceec5e2
commit 8909708588
2 changed files with 6 additions and 6 deletions

View File

@ -58,8 +58,8 @@ namespace HFUTCourseSimulation.Kernel {
_weekWidthWithMargin = _weekWidth + 2 * MARGIN;
_weekHeightWithMargin = _weekHeight + 2 * MARGIN;
_width = _weekWidth * _horizontalCount;
_height = _weekHeight * _verticalCount;
_width = _weekWidthWithMargin * _horizontalCount;
_height = _weekHeightWithMargin * _verticalCount;
}
int _horizontalCount, _verticalCount;
@ -111,7 +111,7 @@ namespace HFUTCourseSimulation.Kernel {
public Rectangle GetHeadbarBoxRect(int week) {
var pos = GetTablePos(week);
return new Rectangle(pos, new Size(7 * CELL_WIDTH, HEADBAR_HEIGHT));
return new Rectangle(pos, new Size(SIDEBAR_WIDTH + 7 * CELL_WIDTH, HEADBAR_HEIGHT));
}
public Rectangle GetSidebarTextRect(int week, int index) {

View File

@ -41,9 +41,9 @@
<TabControl Grid.Row="1" Margin="5">
<TabItem Header="Material Design" Padding="5">
<WrapPanel x:Name="uiMdColorPresetList" Orientation="Horizontal">
</WrapPanel>
<ScrollViewer>
<WrapPanel x:Name="uiMdColorPresetList" Orientation="Horizontal"/>
</ScrollViewer>
</TabItem>
<TabItem Header="Flat UI" Padding="5"/>
<TabItem Header="Fluent" Padding="5"/>