- Removed several unnecessary panels from frmMain (using Anchors instead)

This commit is contained in:
Andreas Schneider 2009-07-31 17:03:26 +02:00
parent dc1f425353
commit f3888db49c
4 changed files with 1086 additions and 1026 deletions

View File

@ -13,7 +13,7 @@ object frmFilter: TfrmFilter
OnCreate = FormCreate OnCreate = FormCreate
OnDestroy = FormDestroy OnDestroy = FormDestroy
OnShow = FormShow OnShow = FormShow
LCLVersion = '0.9.25' LCLVersion = '0.9.27'
object rgFilterType: TRadioGroup object rgFilterType: TRadioGroup
Left = 4 Left = 4
Height = 40 Height = 40
@ -31,15 +31,14 @@ object frmFilter: TfrmFilter
ChildSizing.ShrinkVertical = crsScaleChilds ChildSizing.ShrinkVertical = crsScaleChilds
ChildSizing.Layout = cclLeftToRightThenTopToBottom ChildSizing.Layout = cclLeftToRightThenTopToBottom
ChildSizing.ControlsPerLine = 2 ChildSizing.ControlsPerLine = 2
ClientHeight = 23 ClientHeight = 26
ClientWidth = 224 ClientWidth = 226
Columns = 2 Columns = 2
ItemIndex = 0 ItemIndex = 0
Items.Strings = ( Items.Strings = (
'Exclusive' 'Exclusive'
'Inclusive' 'Inclusive'
) )
ParentFont = True
TabOrder = 0 TabOrder = 0
end end
object GroupBox1: TGroupBox object GroupBox1: TGroupBox
@ -50,52 +49,52 @@ object frmFilter: TfrmFilter
Align = alClient Align = alClient
BorderSpacing.Around = 4 BorderSpacing.Around = 4
Caption = 'Tile filter' Caption = 'Tile filter'
ClientHeight = 242 ClientHeight = 245
ClientWidth = 224 ClientWidth = 226
ParentFont = True
TabOrder = 1 TabOrder = 1
object Label1: TLabel object Label1: TLabel
Left = 4 Left = 4
Height = 28 Height = 30
Top = 28 Top = 30
Width = 216 Width = 218
Align = alTop Align = alTop
BorderSpacing.Around = 4 BorderSpacing.Around = 4
Caption = 'Drag and Drop static tiles from the tile list on this list to add them to the filter.' Caption = 'Drag and Drop static tiles from the tile list on this list to add them to the filter.'
ParentColor = False ParentColor = False
ParentFont = True
WordWrap = True WordWrap = True
end end
object vdtFilter: TVirtualDrawTree object vdtFilter: TVirtualDrawTree
Tag = 1 Tag = 1
Cursor = 63 Cursor = 63
Left = 4 Left = 4
Height = 152 Height = 151
Top = 60 Top = 64
Width = 216 Width = 218
Align = alClient Align = alClient
BorderSpacing.Around = 4 BorderSpacing.Around = 4
BorderStyle = bsSingle BorderStyle = bsSingle
DefaultNodeHeight = 44 DefaultNodeHeight = 44
DragType = dtVCL DragType = dtVCL
Header.Options = [hoColumnResize, hoDrag, hoVisible] Header.AutoSizeIndex = 0
Header.ParentFont = True
Header.Style = hsFlatButtons
Header.Columns = < Header.Columns = <
item item
Position = 0
Text = 'ID' Text = 'ID'
end end
item item
Position = 1 Position = 1
Width = 44
Text = 'Tile' Text = 'Tile'
Width = 44
end end
item item
Position = 2 Position = 2
Width = 100
Text = 'Name' Text = 'Name'
Width = 100
end> end>
ParentFont = True Header.DefaultHeight = 17
Header.Options = [hoColumnResize, hoDrag, hoVisible]
Header.ParentFont = True
Header.Style = hsFlatButtons
TabOrder = 0 TabOrder = 0
TreeOptions.PaintOptions = [toHideFocusRect, toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages] TreeOptions.PaintOptions = [toHideFocusRect, toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages]
TreeOptions.SelectionOptions = [toFullRowSelect, toMultiSelect] TreeOptions.SelectionOptions = [toFullRowSelect, toMultiSelect]
@ -106,19 +105,19 @@ object frmFilter: TfrmFilter
object pnlControls: TPanel object pnlControls: TPanel
Left = 4 Left = 4
Height = 22 Height = 22
Top = 216 Top = 219
Width = 216 Width = 218
Align = alBottom Align = alBottom
BorderSpacing.Around = 4 BorderSpacing.Around = 4
BevelOuter = bvNone BevelOuter = bvNone
ClientHeight = 22 ClientHeight = 22
ClientWidth = 216 ClientWidth = 218
ParentFont = True
TabOrder = 1 TabOrder = 1
object btnDelete: TSpeedButton object btnDelete: TSpeedButton
Left = 84 Left = 84
Height = 22 Height = 22
Hint = 'Delete' Hint = 'Delete'
Top = 0
Width = 23 Width = 23
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
@ -160,13 +159,13 @@ object frmFilter: TfrmFilter
NumGlyphs = 0 NumGlyphs = 0
OnClick = btnDeleteClick OnClick = btnDeleteClick
ShowHint = True ShowHint = True
ParentFont = True
ParentShowHint = False ParentShowHint = False
end end
object btnClear: TSpeedButton object btnClear: TSpeedButton
Left = 108 Left = 108
Height = 22 Height = 22
Hint = 'Clear' Hint = 'Clear'
Top = 0
Width = 23 Width = 23
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
@ -208,20 +207,18 @@ object frmFilter: TfrmFilter
NumGlyphs = 0 NumGlyphs = 0
OnClick = btnClearClick OnClick = btnClearClick
ShowHint = True ShowHint = True
ParentFont = True
ParentShowHint = False ParentShowHint = False
end end
end end
object cbTileFilter: TCheckBox object cbTileFilter: TCheckBox
Left = 4 Left = 4
Height = 20 Height = 22
Top = 4 Top = 4
Width = 216 Width = 218
Align = alTop Align = alTop
BorderSpacing.Around = 4 BorderSpacing.Around = 4
Caption = 'Filter active' Caption = 'Filter active'
Checked = True Checked = True
ParentFont = True
State = cbChecked State = cbChecked
TabOrder = 2 TabOrder = 2
end end
@ -234,49 +231,48 @@ object frmFilter: TfrmFilter
Align = alBottom Align = alBottom
BorderSpacing.Around = 4 BorderSpacing.Around = 4
Caption = 'Hue filter' Caption = 'Hue filter'
ClientHeight = 151 ClientHeight = 154
ClientWidth = 224 ClientWidth = 226
ParentFont = True
TabOrder = 2 TabOrder = 2
object cbHueFilter: TCheckBox object cbHueFilter: TCheckBox
Left = 4 Left = 4
Height = 20 Height = 22
Top = 4 Top = 4
Width = 216 Width = 218
Align = alTop Align = alTop
BorderSpacing.Around = 4 BorderSpacing.Around = 4
Caption = 'Filter active' Caption = 'Filter active'
ParentFont = True
TabOrder = 0 TabOrder = 0
end end
object vdtHues: TVirtualDrawTree object vdtHues: TVirtualDrawTree
Cursor = 63 Cursor = 63
Left = 4 Left = 4
Height = 119 Height = 120
Top = 28 Top = 30
Width = 216 Width = 218
Align = alClient Align = alClient
BorderSpacing.Around = 4 BorderSpacing.Around = 4
BorderStyle = bsSingle BorderStyle = bsSingle
Header.AutoSizeIndex = 2 Header.AutoSizeIndex = 2
Header.Options = [hoAutoResize, hoColumnResize, hoDrag, hoVisible]
Header.ParentFont = True
Header.Style = hsFlatButtons
Header.Columns = < Header.Columns = <
item item
Position = 0
Width = 20 Width = 20
end end
item item
Position = 1 Position = 1
Width = 38
Text = 'Hue' Text = 'Hue'
Width = 38
end end
item item
Position = 2 Position = 2
Width = 158
Text = 'Name' Text = 'Name'
Width = 158
end> end>
ParentFont = True Header.DefaultHeight = 17
Header.Options = [hoAutoResize, hoColumnResize, hoDrag, hoVisible]
Header.ParentFont = True
Header.Style = hsFlatButtons
PopupMenu = pmHues PopupMenu = pmHues
TabOrder = 1 TabOrder = 1
TreeOptions.MiscOptions = [toCheckSupport, toFullRepaintOnResize, toInitOnSave, toToggleOnDblClick, toWheelPanning] TreeOptions.MiscOptions = [toCheckSupport, toFullRepaintOnResize, toInitOnSave, toToggleOnDblClick, toWheelPanning]
@ -288,6 +284,7 @@ object frmFilter: TfrmFilter
end end
object Splitter1: TSplitter object Splitter1: TSplitter
Cursor = crVSplit Cursor = crVSplit
Left = 0
Height = 5 Height = 5
Top = 311 Top = 311
Width = 236 Width = 236

View File

@ -111,8 +111,9 @@ procedure TfrmFilter.FormShow(Sender: TObject);
var var
upperLeft, lowerLeft: TPoint; upperLeft, lowerLeft: TPoint;
begin begin
upperLeft := frmMain.pnlMain.ClientToScreen(Point(0, 0)); upperLeft := frmMain.pcLeft.ClientToScreen(Point(frmMain.pcLeft.Width, 0));
lowerLeft := frmMain.pnlMain.ClientToScreen(Point(0, frmMain.pnlMain.Height)); lowerLeft := frmMain.pcLeft.ClientToScreen(Point(frmMain.pcLeft.Width,
frmMain.pcLeft.Height));
Left := upperLeft.x; Left := upperLeft.x;
Top := upperLeft.y; Top := upperLeft.y;
Height := lowerLeft.y - upperLeft.y; Height := lowerLeft.y - upperLeft.y;

View File

@ -3,7 +3,6 @@ object frmMain: TfrmMain
Height = 603 Height = 603
Top = 126 Top = 126
Width = 766 Width = 766
ActiveControl = pcLeft
Caption = 'UO CentrED' Caption = 'UO CentrED'
ClientHeight = 580 ClientHeight = 580
ClientWidth = 766 ClientWidth = 766
@ -118,62 +117,34 @@ object frmMain: TfrmMain
Caption = 'Tiles' Caption = 'Tiles'
ClientHeight = 492 ClientHeight = 492
ClientWidth = 218 ClientWidth = 218
object pnlTileListSettings: TPanel
Left = 0
Height = 56
Top = 0
Width = 218
Align = alTop
BevelOuter = bvNone
ClientHeight = 56
ClientWidth = 218
TabOrder = 0
object lblFilter: TLabel object lblFilter: TLabel
Left = 84 AnchorSideLeft.Control = cbTerrain
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = cbTerrain
Left = 81
Height = 14 Height = 14
Top = 8 Top = 8
Width = 30 Width = 30
BorderSpacing.Left = 16
Caption = 'Filter:' Caption = 'Filter:'
ParentColor = False ParentColor = False
end end
object cbTerrain: TCheckBox
Left = 4
Height = 22
Top = 8
Width = 61
Caption = 'Terrain'
Checked = True
OnChange = cbTerrainChange
State = cbChecked
TabOrder = 0
end
object cbStatics: TCheckBox
Left = 4
Height = 22
Top = 32
Width = 60
Caption = 'Statics'
Checked = True
OnChange = cbStaticsChange
State = cbChecked
TabOrder = 1
end
object edFilter: TEdit
Left = 84
Height = 19
Top = 24
Width = 112
OnEditingDone = edFilterEditingDone
TabOrder = 2
end
end
object vdtTiles: TVirtualDrawTree object vdtTiles: TVirtualDrawTree
Tag = 1 Tag = 1
Left = 0 AnchorSideLeft.Control = tsTiles
Height = 238 AnchorSideTop.Control = cbStatics
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = tsTiles
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = spTileList
Left = 4
Height = 250
Top = 56 Top = 56
Width = 218 Width = 210
Align = alClient Anchors = [akTop, akLeft, akRight, akBottom]
BorderSpacing.Left = 4
BorderSpacing.Top = 4
BorderSpacing.Right = 4
DefaultNodeHeight = 44 DefaultNodeHeight = 44
DragMode = dmAutomatic DragMode = dmAutomatic
DragType = dtVCL DragType = dtVCL
@ -199,7 +170,7 @@ object frmMain: TfrmMain
Header.ParentFont = True Header.ParentFont = True
Header.Style = hsFlatButtons Header.Style = hsFlatButtons
PopupMenu = pmTileList PopupMenu = pmTileList
TabOrder = 1 TabOrder = 0
TreeOptions.AutoOptions = [toAutoScroll, toAutoScrollOnExpand, toAutoTristateTracking, toAutoDeleteMovedNodes] TreeOptions.AutoOptions = [toAutoScroll, toAutoScrollOnExpand, toAutoTristateTracking, toAutoDeleteMovedNodes]
TreeOptions.MiscOptions = [toFullRepaintOnResize, toInitOnSave, toToggleOnDblClick, toWheelPanning, toFullRowDrag] TreeOptions.MiscOptions = [toFullRepaintOnResize, toInitOnSave, toToggleOnDblClick, toWheelPanning, toFullRowDrag]
TreeOptions.PaintOptions = [toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages, toStaticBackground] TreeOptions.PaintOptions = [toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages, toStaticBackground]
@ -214,71 +185,29 @@ object frmMain: TfrmMain
OnScroll = vdtTilesScroll OnScroll = vdtTilesScroll
end end
object gbRandom: TGroupBox object gbRandom: TGroupBox
AnchorSideTop.Control = spTileList
AnchorSideTop.Side = asrBottom
AnchorSideBottom.Control = tsTiles
AnchorSideBottom.Side = asrBottom
Left = 0 Left = 0
Height = 193 Height = 181
Top = 299 Top = 311
Width = 218 Width = 218
Align = alBottom Align = alBottom
Anchors = [akTop, akLeft, akRight, akBottom]
Caption = 'Random pool' Caption = 'Random pool'
ClientHeight = 179 ClientHeight = 167
ClientWidth = 216
TabOrder = 2
object vdtRandom: TVirtualDrawTree
Tag = 1
Cursor = 63
Left = 0
Height = 127
Top = 22
Width = 216
Align = alClient
DefaultNodeHeight = 44
DragType = dtVCL
Header.AutoSizeIndex = 0
Header.Columns = <
item
Position = 0
Text = 'ID'
end
item
Position = 1
Text = 'Tile'
Width = 44
end
item
Position = 2
Text = 'Name'
Width = 100
end>
Header.DefaultHeight = 17
Header.Options = [hoColumnResize, hoDrag, hoVisible]
Header.ParentFont = True
Header.Style = hsFlatButtons
TabOrder = 0
TreeOptions.PaintOptions = [toHideFocusRect, toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages]
TreeOptions.SelectionOptions = [toFullRowSelect, toMultiSelect]
OnDragOver = vdtRandomDragOver
OnDragDrop = vdtRandomDragDrop
OnDrawNode = vdtTilesDrawNode
OnLoadNode = vdtRandomLoadNode
OnSaveNode = vdtRandomSaveNode
OnUpdating = vdtRandomUpdating
end
object pnlRandomControl: TPanel
Left = 0
Height = 22
Top = 0
Width = 216
Align = alTop
BevelOuter = bvNone
ClientHeight = 22
ClientWidth = 216 ClientWidth = 216
TabOrder = 1 TabOrder = 1
object btnAddRandom: TSpeedButton object btnAddRandom: TSpeedButton
Left = 2 AnchorSideLeft.Control = gbRandom
AnchorSideTop.Control = gbRandom
Left = 4
Height = 22 Height = 22
Hint = 'Add' Hint = 'Add'
Top = 0 Top = 0
Width = 23 Width = 23
BorderSpacing.Left = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -322,11 +251,15 @@ object frmMain: TfrmMain
ParentShowHint = False ParentShowHint = False
end end
object btnDeleteRandom: TSpeedButton object btnDeleteRandom: TSpeedButton
Left = 26 AnchorSideLeft.Control = btnAddRandom
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = btnAddRandom
Left = 31
Height = 22 Height = 22
Hint = 'Delete' Hint = 'Delete'
Top = 0 Top = 0
Width = 23 Width = 23
BorderSpacing.Left = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -370,11 +303,15 @@ object frmMain: TfrmMain
ParentShowHint = False ParentShowHint = False
end end
object btnClearRandom: TSpeedButton object btnClearRandom: TSpeedButton
Left = 50 AnchorSideLeft.Control = btnDeleteRandom
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = btnDeleteRandom
Left = 58
Height = 22 Height = 22
Hint = 'Clear' Hint = 'Clear'
Top = 0 Top = 0
Width = 23 Width = 23
BorderSpacing.Left = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -417,24 +354,16 @@ object frmMain: TfrmMain
ShowHint = True ShowHint = True
ParentShowHint = False ParentShowHint = False
end end
end
object pnlRandomPreset: TPanel
Left = 4
Height = 22
Top = 153
Width = 208
Align = alBottom
BorderSpacing.Around = 4
BevelOuter = bvNone
ClientHeight = 22
ClientWidth = 208
TabOrder = 2
object btnRandomPresetSave: TSpeedButton object btnRandomPresetSave: TSpeedButton
Left = 158 AnchorSideTop.Control = cbRandomPreset
AnchorSideRight.Control = btnRandomPresetDelete
Left = 164
Height = 22 Height = 22
Hint = 'Save Preset' Hint = 'Save Preset'
Top = 0 Top = 134
Width = 23 Width = 22
Anchors = [akTop, akRight]
BorderSpacing.Right = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -479,11 +408,16 @@ object frmMain: TfrmMain
ParentShowHint = False ParentShowHint = False
end end
object btnRandomPresetDelete: TSpeedButton object btnRandomPresetDelete: TSpeedButton
Left = 182 AnchorSideTop.Control = btnRandomPresetSave
AnchorSideRight.Control = gbRandom
AnchorSideRight.Side = asrBottom
Left = 190
Height = 22 Height = 22
Hint = 'Delete Preset' Hint = 'Delete Preset'
Top = 0 Top = 134
Width = 23 Width = 22
Anchors = [akTop, akRight]
BorderSpacing.Right = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -527,41 +461,154 @@ object frmMain: TfrmMain
ShowHint = True ShowHint = True
ParentShowHint = False ParentShowHint = False
end end
object vdtRandom: TVirtualDrawTree
Tag = 1
AnchorSideLeft.Control = gbRandom
AnchorSideTop.Control = btnAddRandom
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = gbRandom
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = cbRandomPreset
Cursor = 63
Left = 4
Height = 106
Top = 24
Width = 208
Anchors = [akTop, akLeft, akRight, akBottom]
BorderSpacing.Left = 4
BorderSpacing.Top = 2
BorderSpacing.Right = 4
BorderSpacing.Bottom = 4
DefaultNodeHeight = 44
DragType = dtVCL
Header.AutoSizeIndex = 0
Header.Columns = <
item
Position = 0
Text = 'ID'
end
item
Position = 1
Text = 'Tile'
Width = 44
end
item
Position = 2
Text = 'Name'
Width = 100
end>
Header.DefaultHeight = 17
Header.Options = [hoColumnResize, hoDrag, hoVisible]
Header.ParentFont = True
Header.Style = hsFlatButtons
TabOrder = 0
TreeOptions.PaintOptions = [toHideFocusRect, toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages]
TreeOptions.SelectionOptions = [toFullRowSelect, toMultiSelect]
OnDragOver = vdtRandomDragOver
OnDragDrop = vdtRandomDragDrop
OnDrawNode = vdtTilesDrawNode
OnLoadNode = vdtRandomLoadNode
OnSaveNode = vdtRandomSaveNode
OnUpdating = vdtRandomUpdating
end
object cbRandomPreset: TComboBox object cbRandomPreset: TComboBox
Left = 0 AnchorSideLeft.Control = gbRandom
AnchorSideRight.Control = btnRandomPresetSave
AnchorSideBottom.Control = gbRandom
AnchorSideBottom.Side = asrBottom
Left = 4
Height = 29 Height = 29
Top = 0 Top = 134
Width = 152 Width = 156
Anchors = [akLeft, akRight, akBottom]
BorderSpacing.Left = 4
BorderSpacing.Right = 4
BorderSpacing.Bottom = 4
ItemHeight = 0 ItemHeight = 0
OnChange = cbRandomPresetChange OnChange = cbRandomPresetChange
Style = csDropDownList Style = csDropDownList
TabOrder = 0 TabOrder = 1
end
end end
end end
object spTileList: TSplitter object spTileList: TSplitter
AnchorSideLeft.Control = tsTiles
AnchorSideRight.Control = tsTiles
AnchorSideRight.Side = asrBottom
Cursor = crVSplit Cursor = crVSplit
Left = 0 Left = 0
Height = 5 Height = 5
Top = 294 Top = 306
Width = 218 Width = 218
Align = alBottom Align = alNone
Anchors = [akTop, akLeft, akRight]
ResizeAnchor = akBottom ResizeAnchor = akBottom
end end
object edSearchID: TEdit object edSearchID: TEdit
Left = 118 AnchorSideRight.Control = vdtTiles
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = vdtTiles
AnchorSideBottom.Side = asrBottom
Left = 114
Height = 19 Height = 19
Hint = 'Append S or T to restrict the search to Statics or Terrain.' Hint = 'Append S or T to restrict the search to Statics or Terrain.'
Top = 256 Top = 283
Width = 96 Width = 96
Anchors = [akRight, akBottom]
BorderSpacing.Right = 4
BorderSpacing.Bottom = 4
CharCase = ecUppercase CharCase = ecUppercase
OnExit = edSearchIDExit OnExit = edSearchIDExit
OnKeyPress = edSearchIDKeyPress OnKeyPress = edSearchIDKeyPress
ParentShowHint = False ParentShowHint = False
ShowHint = True ShowHint = True
TabOrder = 3 TabOrder = 2
Visible = False Visible = False
end end
object edFilter: TEdit
AnchorSideLeft.Control = lblFilter
AnchorSideTop.Control = lblFilter
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = tsTiles
AnchorSideRight.Side = asrBottom
Left = 81
Height = 19
Top = 22
Width = 121
Anchors = [akTop, akLeft, akRight]
BorderSpacing.Right = 16
OnEditingDone = edFilterEditingDone
TabOrder = 4
end
object cbStatics: TCheckBox
AnchorSideLeft.Control = cbTerrain
AnchorSideLeft.Side = asrCenter
AnchorSideTop.Control = cbTerrain
AnchorSideTop.Side = asrBottom
Left = 4
Height = 22
Top = 30
Width = 60
Caption = 'Statics'
Checked = True
OnChange = cbStaticsChange
State = cbChecked
TabOrder = 5
end
object cbTerrain: TCheckBox
AnchorSideLeft.Control = tsTiles
AnchorSideTop.Control = tsTiles
Left = 4
Height = 22
Top = 8
Width = 61
BorderSpacing.Left = 4
BorderSpacing.Top = 8
Caption = 'Terrain'
Checked = True
OnChange = cbTerrainChange
State = cbChecked
TabOrder = 6
end
end end
object tsClients: TTabSheet object tsClients: TTabSheet
Caption = 'Clients' Caption = 'Clients'
@ -585,60 +632,16 @@ object frmMain: TfrmMain
Caption = 'Locations' Caption = 'Locations'
ClientHeight = 492 ClientHeight = 492
ClientWidth = 218 ClientWidth = 218
object vstLocations: TVirtualStringTree
Cursor = 63
Left = 4
Height = 456
Top = 4
Width = 210
Align = alClient
BorderSpacing.Around = 4
BorderStyle = bsSingle
DefaultText = 'Node'
Header.AutoSizeIndex = 1
Header.Columns = <
item
Position = 0
Text = 'Coords'
Width = 75
end
item
Position = 1
Text = 'Name'
Width = 131
end>
Header.DefaultHeight = 17
Header.Options = [hoAutoResize, hoColumnResize, hoDrag, hoVisible]
Header.ParentFont = True
Header.Style = hsFlatButtons
TabOrder = 0
TreeOptions.AutoOptions = [toAutoScrollOnExpand, toAutoTristateTracking, toAutoDeleteMovedNodes]
TreeOptions.PaintOptions = [toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages]
TreeOptions.SelectionOptions = [toFullRowSelect]
OnDblClick = vstLocationsDblClick
OnFreeNode = vstLocationsFreeNode
OnGetText = vstLocationsGetText
OnLoadNode = vstLocationsLoadNode
OnNewText = vstLocationsNewText
OnSaveNode = vstLocationsSaveNode
end
object pnlLocationControls: TPanel
Left = 4
Height = 24
Top = 464
Width = 210
Align = alBottom
BorderSpacing.Around = 4
BevelOuter = bvNone
ClientHeight = 24
ClientWidth = 210
TabOrder = 1
object btnClearLocations: TSpeedButton object btnClearLocations: TSpeedButton
Left = 112 AnchorSideLeft.Control = btnDeleteLocation
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = btnDeleteLocation
Left = 128
Height = 22 Height = 22
Hint = 'Clear' Hint = 'Clear'
Top = 0 Top = 450
Width = 23 Width = 23
BorderSpacing.Left = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -682,11 +685,17 @@ object frmMain: TfrmMain
ParentShowHint = False ParentShowHint = False
end end
object btnDeleteLocation: TSpeedButton object btnDeleteLocation: TSpeedButton
Left = 88 AnchorSideLeft.Control = tsLocations
AnchorSideLeft.Side = asrCenter
AnchorSideBottom.Control = tsLocations
AnchorSideBottom.Side = asrBottom
Left = 101
Height = 22 Height = 22
Hint = 'Delete' Hint = 'Delete'
Top = 0 Top = 450
Width = 23 Width = 23
Anchors = [akLeft, akBottom]
BorderSpacing.Bottom = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -730,11 +739,15 @@ object frmMain: TfrmMain
ParentShowHint = False ParentShowHint = False
end end
object btnAddLocation: TSpeedButton object btnAddLocation: TSpeedButton
Left = 64 AnchorSideTop.Control = btnDeleteLocation
AnchorSideRight.Control = btnDeleteLocation
Left = 74
Height = 22 Height = 22
Hint = 'Add' Hint = 'Add'
Top = 0 Top = 450
Width = 23 Width = 23
Anchors = [akTop, akRight]
BorderSpacing.Right = 4
Color = clBtnFace Color = clBtnFace
Glyph.Data = { Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100 36040000424D3604000000000000360000002800000010000000100000000100
@ -777,6 +790,47 @@ object frmMain: TfrmMain
ShowHint = True ShowHint = True
ParentShowHint = False ParentShowHint = False
end end
object vstLocations: TVirtualStringTree
AnchorSideLeft.Control = tsLocations
AnchorSideTop.Control = tsLocations
AnchorSideRight.Control = tsLocations
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = btnDeleteLocation
Cursor = 63
Left = 4
Height = 428
Top = 18
Width = 210
Anchors = [akTop, akLeft, akRight, akBottom]
BorderSpacing.Around = 4
BorderStyle = bsSingle
DefaultText = 'Node'
Header.AutoSizeIndex = 1
Header.Columns = <
item
Position = 0
Text = 'Coords'
Width = 75
end
item
Position = 1
Text = 'Name'
Width = 131
end>
Header.DefaultHeight = 17
Header.Options = [hoAutoResize, hoColumnResize, hoDrag, hoVisible]
Header.ParentFont = True
Header.Style = hsFlatButtons
TabOrder = 0
TreeOptions.AutoOptions = [toAutoScrollOnExpand, toAutoTristateTracking, toAutoDeleteMovedNodes]
TreeOptions.PaintOptions = [toShowButtons, toShowDropmark, toThemeAware, toUseBlendedImages]
TreeOptions.SelectionOptions = [toFullRowSelect]
OnDblClick = vstLocationsDblClick
OnFreeNode = vstLocationsFreeNode
OnGetText = vstLocationsGetText
OnLoadNode = vstLocationsLoadNode
OnNewText = vstLocationsNewText
OnSaveNode = vstLocationsSaveNode
end end
end end
end end
@ -945,47 +999,27 @@ object frmMain: TfrmMain
Style = tbsCheck Style = tbsCheck
end end
end end
object pnlMain: TPanel
Left = 224
Height = 525
Top = 24
Width = 542
Align = alClient
BevelOuter = bvNone
ClientHeight = 525
ClientWidth = 542
TabOrder = 3
object oglGameWindow: TOpenGLControl
Left = 0
Height = 374
Top = 0
Width = 542
Align = alClient
OnDblClick = oglGameWindowDblClick
OnMouseDown = oglGameWindowMouseDown
OnMouseEnter = oglGameWindowMouseEnter
OnMouseLeave = oglGameWindowMouseLeave
OnMouseMove = oglGameWindowMouseMove
OnMouseUp = oglGameWindowMouseUp
OnMouseWheel = oglGameWindowMouseWheel
OnPaint = oglGameWindowPaint
OnResize = oglGameWindowResize
end
object pnlChatHeader: TPanel object pnlChatHeader: TPanel
Left = 0 AnchorSideLeft.Control = pnlChat
Height = 24 AnchorSideTop.Control = spChat
Top = 374 AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = pnlChat
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = spChat
Left = 224
Height = 22
Top = 413
Width = 542 Width = 542
Align = alBottom Anchors = [akLeft, akRight, akBottom]
BevelInner = bvRaised BevelInner = bvRaised
BevelOuter = bvLowered BevelOuter = bvLowered
ClientHeight = 24 ClientHeight = 22
ClientWidth = 542 ClientWidth = 542
TabOrder = 0 TabOrder = 3
object lblChatHeaderCaption: TLabel object lblChatHeaderCaption: TLabel
Cursor = crHandPoint Cursor = crHandPoint
Left = 10 Left = 10
Height = 20 Height = 18
Top = 2 Top = 2
Width = 104 Width = 104
Align = alLeft Align = alLeft
@ -999,20 +1033,27 @@ object frmMain: TfrmMain
end end
end end
object pnlChat: TPanel object pnlChat: TPanel
Left = 0 AnchorSideLeft.Control = pcLeft
Height = 122 AnchorSideLeft.Side = asrBottom
Top = 403 AnchorSideTop.Control = spChat
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = Owner
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = pnlBottom
Left = 224
Height = 109
Top = 440
Width = 542 Width = 542
Align = alBottom Anchors = [akTop, akLeft, akRight, akBottom]
BevelOuter = bvNone BevelOuter = bvNone
ClientHeight = 122 ClientHeight = 109
ClientWidth = 542 ClientWidth = 542
TabOrder = 1 TabOrder = 4
Visible = False Visible = False
object vstChat: TVirtualStringTree object vstChat: TVirtualStringTree
Cursor = 63 Cursor = 63
Left = 0 Left = 0
Height = 103 Height = 90
Top = 0 Top = 0
Width = 542 Width = 542
Align = alClient Align = alClient
@ -1051,7 +1092,7 @@ object frmMain: TfrmMain
object edChat: TEdit object edChat: TEdit
Left = 0 Left = 0
Height = 19 Height = 19
Top = 103 Top = 90
Width = 542 Width = 542
Align = alBottom Align = alBottom
OnKeyPress = edChatKeyPress OnKeyPress = edChatKeyPress
@ -1059,17 +1100,43 @@ object frmMain: TfrmMain
end end
end end
object spChat: TSplitter object spChat: TSplitter
AnchorSideLeft.Control = pcLeft
AnchorSideLeft.Side = asrBottom
AnchorSideRight.Control = Owner
AnchorSideRight.Side = asrBottom
Cursor = crVSplit Cursor = crVSplit
Left = 0 Left = 224
Height = 5 Height = 5
Top = 398 Top = 435
Width = 542 Width = 542
Align = alBottom Align = alNone
Anchors = [akLeft, akRight]
AutoSnap = False AutoSnap = False
MinSize = 100
ResizeAnchor = akBottom ResizeAnchor = akBottom
Visible = False Visible = False
end end
object oglGameWindow: TOpenGLControl
AnchorSideLeft.Control = pcLeft
AnchorSideLeft.Side = asrBottom
AnchorSideTop.Control = tbMain
AnchorSideTop.Side = asrBottom
AnchorSideRight.Control = Owner
AnchorSideRight.Side = asrBottom
AnchorSideBottom.Control = pnlChatHeader
Left = 224
Height = 389
Top = 24
Width = 542
Anchors = [akTop, akLeft, akRight, akBottom]
OnDblClick = oglGameWindowDblClick
OnMouseDown = oglGameWindowMouseDown
OnMouseEnter = oglGameWindowMouseEnter
OnMouseLeave = oglGameWindowMouseLeave
OnMouseMove = oglGameWindowMouseMove
OnMouseUp = oglGameWindowMouseUp
OnMouseWheel = oglGameWindowMouseWheel
OnPaint = oglGameWindowPaint
OnResize = oglGameWindowResize
end end
object MainMenu1: TMainMenu object MainMenu1: TMainMenu
Images = ImageList1 Images = ImageList1
@ -1993,7 +2060,7 @@ object frmMain: TfrmMain
} }
end end
object pmTileList: TPopupMenu object pmTileList: TPopupMenu
left = 185 left = 184
top = 128 top = 128
object mnuAddToRandom: TMenuItem object mnuAddToRandom: TMenuItem
Caption = 'Add to random pool' Caption = 'Add to random pool'
@ -2346,8 +2413,8 @@ object frmMain: TfrmMain
end end
end end
object pmClients: TPopupMenu object pmClients: TPopupMenu
left = 185 left = 184
top = 163 top = 168
object mnuGoToClient: TMenuItem object mnuGoToClient: TMenuItem
Caption = 'GoTo' Caption = 'GoTo'
Default = True Default = True
@ -2461,19 +2528,6 @@ object frmMain: TfrmMain
OnExecute = acNoDrawExecute OnExecute = acNoDrawExecute
end end
end end
object pmGrabTileInfo: TPopupMenu
OnPopup = pmGrabTileInfoPopup
left = 368
top = 32
object mnuGrabTileID: TMenuItem
Caption = 'Grab TileID'
OnClick = mnuGrabTileIDClick
end
object mnuGrabHue: TMenuItem
Caption = 'Grab Hue'
OnClick = mnuGrabHueClick
end
end
object tmGrabTileInfo: TTimer object tmGrabTileInfo: TTimer
Enabled = False Enabled = False
Interval = 250 Interval = 250
@ -2487,4 +2541,17 @@ object frmMain: TfrmMain
left = 185 left = 185
top = 200 top = 200
end end
object pmGrabTileInfo: TPopupMenu
OnPopup = pmGrabTileInfoPopup
left = 368
top = 33
object mnuGrabTileID: TMenuItem
Caption = 'Grab TileID'
OnClick = mnuGrabTileIDClick
end
object mnuGrabHue: TMenuItem
Caption = 'Grab Hue'
OnClick = mnuGrabHueClick
end
end
end end

View File

@ -60,30 +60,35 @@ type
ActionList1: TActionList; ActionList1: TActionList;
ApplicationProperties1: TApplicationProperties; ApplicationProperties1: TApplicationProperties;
btnAddLocation: TSpeedButton; btnAddLocation: TSpeedButton;
btnAddRandom: TSpeedButton;
btnClearLocations: TSpeedButton; btnClearLocations: TSpeedButton;
btnClearRandom: TSpeedButton;
btnDeleteLocation: TSpeedButton; btnDeleteLocation: TSpeedButton;
btnDeleteRandom: TSpeedButton;
btnGoTo: TButton; btnGoTo: TButton;
btnRandomPresetDelete: TSpeedButton;
btnRandomPresetSave: TSpeedButton;
cbRandomPreset: TComboBox; cbRandomPreset: TComboBox;
cbTerrain: TCheckBox;
cbStatics: TCheckBox; cbStatics: TCheckBox;
edFilter: TEdit; cbTerrain: TCheckBox;
edChat: TEdit; edChat: TEdit;
edFilter: TEdit;
edSearchID: TEdit; edSearchID: TEdit;
gbRandom: TGroupBox; gbRandom: TGroupBox;
ImageList1: TImageList; ImageList1: TImageList;
lblChatHeaderCaption: TLabel; lblChatHeaderCaption: TLabel;
lblFilter: TLabel;
lblTipC: TLabel; lblTipC: TLabel;
lblTip: TLabel; lblTip: TLabel;
lblTileInfo: TLabel; lblTileInfo: TLabel;
lblFilter: TLabel;
lblX: TLabel; lblX: TLabel;
lblY: TLabel; lblY: TLabel;
lbClients: TListBox; lbClients: TListBox;
MainMenu1: TMainMenu; MainMenu1: TMainMenu;
mnuGrabHue: TMenuItem;
mnuGrabTileID: TMenuItem;
mnuRegionControl: TMenuItem; mnuRegionControl: TMenuItem;
mnuVirtualLayer: TMenuItem; mnuVirtualLayer: TMenuItem;
mnuGrabTileID: TMenuItem;
mnuGrabHue: TMenuItem;
mnuLargeScaleCommands: TMenuItem; mnuLargeScaleCommands: TMenuItem;
mnuSetHue: TMenuItem; mnuSetHue: TMenuItem;
mnuGoToClient: TMenuItem; mnuGoToClient: TMenuItem;
@ -107,27 +112,17 @@ type
mnuDisconnect: TMenuItem; mnuDisconnect: TMenuItem;
mnuCentrED: TMenuItem; mnuCentrED: TMenuItem;
oglGameWindow: TOpenGLControl; oglGameWindow: TOpenGLControl;
pnlRandomPreset: TPanel;
pnlLocationControls: TPanel;
pnlChat: TPanel;
pnlChatHeader: TPanel;
pnlMain: TPanel;
pnlRandomControl: TPanel;
pnlTileListSettings: TPanel;
pcLeft: TPageControl; pcLeft: TPageControl;
pmGrabTileInfo: TPopupMenu;
pnlBottom: TPanel; pnlBottom: TPanel;
edX: TSpinEdit; edX: TSpinEdit;
edY: TSpinEdit; edY: TSpinEdit;
pmTileList: TPopupMenu; pmTileList: TPopupMenu;
btnAddRandom: TSpeedButton;
btnDeleteRandom: TSpeedButton;
btnClearRandom: TSpeedButton;
pmTools: TPopupMenu; pmTools: TPopupMenu;
pmClients: TPopupMenu; pmClients: TPopupMenu;
pmGrabTileInfo: TPopupMenu; pnlChat: TPanel;
pnlChatHeader: TPanel;
spChat: TSplitter; spChat: TSplitter;
btnRandomPresetSave: TSpeedButton;
btnRandomPresetDelete: TSpeedButton;
spTileList: TSplitter; spTileList: TSplitter;
tbFilter: TToolButton; tbFilter: TToolButton;
tbFlat: TToolButton; tbFlat: TToolButton;
@ -157,8 +152,8 @@ type
tsTiles: TTabSheet; tsTiles: TTabSheet;
vdtTiles: TVirtualDrawTree; vdtTiles: TVirtualDrawTree;
vdtRandom: TVirtualDrawTree; vdtRandom: TVirtualDrawTree;
vstLocations: TVirtualStringTree;
vstChat: TVirtualStringTree; vstChat: TVirtualStringTree;
vstLocations: TVirtualStringTree;
procedure acBoundariesExecute(Sender: TObject); procedure acBoundariesExecute(Sender: TObject);
procedure acDeleteExecute(Sender: TObject); procedure acDeleteExecute(Sender: TObject);
procedure acDrawExecute(Sender: TObject); procedure acDrawExecute(Sender: TObject);
@ -739,6 +734,7 @@ begin
Randomize; Randomize;
vstChat.NodeDataSize := SizeOf(TChatInfo); vstChat.NodeDataSize := SizeOf(TChatInfo);
pnlChatHeader.AnchorSide[akBottom].Control := pnlBottom;
FLocationsFile := IncludeTrailingPathDelimiter(ExtractFilePath( FLocationsFile := IncludeTrailingPathDelimiter(ExtractFilePath(
Application.ExeName)) + 'Locations.dat'; Application.ExeName)) + 'Locations.dat';
@ -1113,12 +1109,13 @@ begin
begin begin
pnlChat.Visible := False; pnlChat.Visible := False;
spChat.Visible := False; spChat.Visible := False;
pnlChatHeader.AnchorSide[akBottom].Control := pnlBottom;
end else end else
begin begin
spChat.Visible := True; spChat.Visible := True;
pnlChat.Visible := True; pnlChat.Visible := True;
spChat.Top := pnlChatHeader.Top + pnlChatHeader.Height; spChat.Top := pnlChat.Top - spChat.Height;
pnlChat.Top := spChat.Top + spChat.Height; pnlChatHeader.AnchorSide[akBottom].Control := spChat;
lblChatHeaderCaption.Font.Bold := False; lblChatHeaderCaption.Font.Bold := False;
lblChatHeaderCaption.Font.Italic := False; lblChatHeaderCaption.Font.Italic := False;
@ -1368,8 +1365,6 @@ procedure TfrmMain.vdtTilesKeyPress(Sender: TObject; var Key: char);
begin begin
if Key in ['$', '0'..'9'] then if Key in ['$', '0'..'9'] then
begin begin
edSearchID.Top := vdtTiles.Top + vdtTiles.Height - edSearchID.Height - 4;
edSearchID.Left := vdtTiles.Left + vdtTiles.Width - edSearchID.Width - 4;
edSearchID.Text := Key; edSearchID.Text := Key;
edSearchID.Visible := True; edSearchID.Visible := True;
edSearchID.SetFocus; edSearchID.SetFocus;