From ad1384d37a197a4dcce1c8966ee09f184e36ea14 Mon Sep 17 00:00:00 2001 From: q9_ Date: Thu, 11 Mar 2004 14:54:43 +0000 Subject: [PATCH] =?utf8?q?=E3=82=B9=E3=83=AC=E4=B8=80=E8=A6=A7=E7=AD=89?= =?utf8?q?=E3=81=AE=E3=82=AB=E3=83=A9=E3=83=A0=E5=B9=85=E3=82=922000?= =?utf8?q?=E3=81=AB=E5=88=B6=E9=99=90=E3=81=97=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- Setting.pas | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Setting.pas b/Setting.pas index 50f71ce..3726cd5 100644 --- a/Setting.pas +++ b/Setting.pas @@ -619,6 +619,7 @@ const DEFAULT_BBS_WIDTH: array[0..0] of Integer = (140); DEFAULT_CATEGORY_WIDTH: array[0..3] of Integer = (150, 80, 130, 130); DEFAULT_BOARD_WIDTH: array[0..7] of Integer = (350, 60, 60, 60, 60, 80, 130, 130); + MAX_WIDTH: Integer = 2000; var ini: TMemIniFile; i: Integer; @@ -781,6 +782,8 @@ begin end; for i := 0 to Length(FBBSColumnWidth) - 1 do begin BBSColumnWidth[i] := ini.ReadInteger('BBSColumnWidth', 'ID' + IntToStr(i), DEFAULT_BBS_WIDTH[i]); + if BBSColumnWidth[i] > MAX_WIDTH then + BBSColumnWidth[i] := DEFAULT_BBS_WIDTH[i]; end; ini.ReadSection('CategoryColumnWidth', wkList); if Length(FCategoryColumnWidth) <> wkList.Count then begin @@ -788,6 +791,8 @@ begin end; for i := 0 to Length(FCategoryColumnWidth) - 1 do begin CategoryColumnWidth[i] := ini.ReadInteger('CategoryColumnWidth', 'ID' + IntToStr(i), DEFAULT_CATEGORY_WIDTH[i]); + if CategoryColumnWidth[i] > MAX_WIDTH then + CategoryColumnWidth[i] := DEFAULT_CATEGORY_WIDTH[i]; end; ini.ReadSection('BoardColumnWidth', wkList); if Length(FBoardColumnWidth) <> wkList.Count then begin @@ -795,6 +800,8 @@ begin end; for i := 0 to Length(FBoardColumnWidth) - 1 do begin BoardColumnWidth[i] := ini.ReadInteger('BoardColumnWidth', 'ID' + IntToStr(i), DEFAULT_BOARD_WIDTH[i]); + if BoardColumnWidth[i] > MAX_WIDTH then + BoardColumnWidth[i] := DEFAULT_BOARD_WIDTH[i]; end; finally wkList.Free; -- 2.11.0