diff options
Diffstat (limited to 'examples/apps/uidesigner')
-rw-r--r-- | examples/apps/uidesigner/vfddesigner.pas | 3 | ||||
-rw-r--r-- | examples/apps/uidesigner/vfdwidgetclass.pas | 8 |
2 files changed, 9 insertions, 2 deletions
diff --git a/examples/apps/uidesigner/vfddesigner.pas b/examples/apps/uidesigner/vfddesigner.pas index 30fce227..e070e0a5 100644 --- a/examples/apps/uidesigner/vfddesigner.pas +++ b/examples/apps/uidesigner/vfddesigner.pas @@ -103,6 +103,7 @@ type procedure MsgMove(var msg: TfpgMessageRec); message FPGM_MOVE; procedure MsgResize(var msg: TfpgMessageRec); message FPGM_RESIZE; procedure MsgActivate(var msg: TfpgMessageRec); message FPGM_ACTIVATE; + procedure DesignerKeyPress(var keycode: word; var shiftstate: TShiftState; var consumed: boolean); public OneClickMove: boolean; // the widgets can be selected and dragged within one click constructor Create; @@ -119,7 +120,6 @@ type procedure MoveResizeWidgets(dx, dy, dw, dh: integer); procedure DeleteWidgets; procedure EditWidgetOrder; - procedure DesignerKeyPress(var keycode: word; var shiftstate: TShiftState; var consumed: boolean); // procedure PutControlByName(x, y: integer; cname: string); procedure InsertWidget(pwg: TfpgWidget; x, y: integer; wgc: TVFDWidgetClass); procedure OnPaletteChange(Sender: TObject); @@ -606,6 +606,7 @@ begin else Inc(n); end; + UpdatePropWin; end; diff --git a/examples/apps/uidesigner/vfdwidgetclass.pas b/examples/apps/uidesigner/vfdwidgetclass.pas index e6f0add2..b1c7eee0 100644 --- a/examples/apps/uidesigner/vfdwidgetclass.pas +++ b/examples/apps/uidesigner/vfdwidgetclass.pas @@ -167,7 +167,13 @@ begin y := rect.top; fy := y + rect.Height div 2 - Canvas.Font.Height div 2; - s := GetValueText(wg); + try + s := GetValueText(wg); + except + on E: Exception do + writeln('Detected a error: ', E.Message); + end; + Canvas.BeginDraw; Canvas.DrawString(x + 1, fy, s); Canvas.EndDraw; |