TTIPropertyGrid > inhalt updaten

Rund um die LCL und andere Komponenten
schnullerbacke
Beiträge: 1187
Registriert: Mi 13. Dez 2006, 10:58
OS, Lazarus, FPC: Winux (L 1.2.xy FPC 2.6.z)
CPU-Target: AMD A4-6400 APU
Wohnort: Hamburg

Beitrag von schnullerbacke »

Da kannste ja mal auf TBitmap nen Rechtsklick machen und "Suche Delaration" auswälen. Dann kannste Dir ansehen, was das alles als Property zur Verfügung steht. Interessant können eh nur die sein, die schon public sind. Bei den anderen Kann es sonst haarig werden.
Humor ist der Knopf, der verhindert, daß uns der Kragen platzt.

(Ringelnatz)

pluto
Lazarusforum e. V.
Beiträge: 7178
Registriert: So 19. Nov 2006, 12:06
OS, Lazarus, FPC: Linux Mint 19.3
CPU-Target: AMD
Wohnort: Oldenburg(Oldenburg)

Beitrag von pluto »

deine idee brachte mich leider nicht viel weiter... ich bin mal duch den qullcode gegangen von den OI... dort habe ich folgenden text gefunden, leider in englisch... ich hoffe ihr/du kannst mir den übersetzten bzw. sagen ob dieses text für mein vorhaben hilfreich ist....

vielen dank im vorraus...
hier ist der text:
{ TPropertyEditor
Edits a property of a component, or list of components, selected into the
Object Inspector. The property editor is created based on the type of the
property being edited as determined by the types registered by
RegisterPropertyEditor. The Object Inspector uses a TPropertyEditor
for all modification to a property. GetName and GetValue are called to
display the name and value of the property. SetValue is called whenever the
user requests to change the value. Edit is called when the user
double-clicks the property in the Object Inspector. GetValues is called when
the drop-down list of a property is displayed. GetProperties is called when
the property is expanded to show sub-properties. AllEqual is called to decide
whether or not to display the value of the property when more than one
component is selected.

The following are methods that can be overridden to change the behavior of
the property editor:

Activate
Called whenever the property becomes selected in the object inspector.
This is potentially useful to allow certain property attributes to
to only be determined whenever the property is selected in the object
inspector. Only paSubProperties and paMultiSelect,returned from
GetAttributes,need to be accurate before this method is called.
Deactivate
Called whenevr the property becomes unselected in the object inspector.
AllEqual
Called whenever there is more than one component selected. If this
method returns true,GetValue is called,otherwise blank is displayed
in the Object Inspector. This is called only when GetAttributes
returns paMultiSelect.
AutoFill
Called to determine whether the values returned by GetValues can be
selected incrementally in the Object Inspector. This is called only when
GetAttributes returns paValueList.
Edit
Called when the '...' button is pressed or the property is double-clicked.
This can,for example,bring up a dialog to allow the editing the
component in some more meaningful fashion than by text (e.g. the Font
property).
GetAttributes
Returns the information for use in the Object Inspector to be able to
show the appropriate tools. GetAttributes returns a set of type
TPropertyAttributes:
paValueList: The property editor can return an enumerated list of
values for the property. If GetValues calls Proc
with values then this attribute should be set. This
will cause the drop-down button to appear to the right
of the property in the Object Inspector.
paSortList: Object Inspector to sort the list returned by
GetValues.
paSubProperties:The property editor has sub-properties that will be
displayed indented and below the current property in
standard outline format. If GetProperties will
generate property objects then this attribute should
be set.
paDynamicSubProps:The sub properties can change. All designer tools
(e.g. property editors, component editors) that change
the list should call UpdateListPropertyEditors, so that
the object inspector will reread the subproperties.
paDialog: Indicates that the Edit method will bring up a
dialog. This will cause the '...' button to be
displayed to the right of the property in the Object
Inspector.
paMultiSelect: Allows the property to be displayed when more than
one component is selected. Some properties are not
appropriate for multi-selection (e.g. the Name
property).
paAutoUpdate: Causes the SetValue method to be called on each
change made to the editor instead of after the change
has been approved (e.g. the Caption property).
paReadOnly: Value is not allowed to change. But if paDialog is set
a Dialog can change the value. This disbales only the
edit and combobox in the object inspector.
paRevertable: Allows the property to be reverted to the original
value. Things that shouldn't be reverted are nested
properties (e.g. Fonts) and elements of a composite
property such as set element values.
paFullWidthName:Tells the object inspector that the value does not
need to be rendered and as such the name should be
rendered the full width of the inspector.
paVolatileSubProperties: Any change of property value causes any shown
subproperties to be recollected.
paDisableSubProperties: All subproperties are readonly
(not even via Dialog).
paReference: property contains a reference to something else. When
used in conjunction with paSubProperties the referenced
object should be displayed as sub properties to this
property.
paNotNestable: Indicates that the property is not safe to show when
showing the properties of an expanded reference.

GetComponent
Returns the Index'th component being edited by this property editor. This
is used to retrieve the components. A property editor can only refer to
multiple components when paMultiSelect is returned from GetAttributes.
GetEditLimit
Returns the number of character the user is allowed to enter for the
value. The inplace editor of the object inspector will be have its
text limited set to the return value. By default this limit is 255.
GetName
Returns the name of the property. By default the value is retrieved
from the type information with all underbars replaced by spaces. This
should only be overridden if the name of the property is not the name
that should appear in the Object Inspector.
GetProperties
Should be overridden to call PropertyProc for every sub-property (or
nested property) of the property begin edited and passing a new
TPropertyEdtior for each sub-property. By default,PropertyProc is not
called and no sub-properties are assumed. TClassPropertyEditor will pass a
new property editor for each published property in a class.
TSetPropertyEditor passes a new editor for each element in the set.
GetPropType
Returns the type information pointer for the property(s) being edited.
GetValue
Returns the string value of the property. By default this returns
'(unknown)'. This should be overridden to return the appropriate value.
GetValues
Called when paValueList is returned in GetAttributes. Should call Proc
for every value that is acceptable for this property. TEnumPropertyEditor
will pass every element in the enumeration.
Initialize
Called after the property editor has been created but before it is used.
Many times property editors are created and because they are not a common
property across the entire selection they are thrown away. Initialize is
called after it is determined the property editor is going to be used by
the object inspector and not just thrown away.
SetValue(Value)
Called to set the value of the property. The property editor should be
able to translate the string and call one of the SetXxxValue methods. If
the string is not in the correct format or not an allowed value,the
property editor should generate an exception describing the problem. Set
value can ignore all changes and allow all editing of the property be
accomplished through the Edit method (e.g. the Picture property).
ListMeasureWidth(Value,Canvas,AWidth)
This is called during the width calculation phase of the drop down list
preparation.
ListMeasureHeight(Value,Canvas,AHeight)
This is called during the item/value height calculation phase of the drop
down list's render. This is very similar to TListBox's OnMeasureItem,
just slightly different parameters.
ListDrawValue(Value,Canvas,Rect,Selected)
This is called during the item/value render phase of the drop down list's
render. This is very similar to TListBox's OnDrawItem, just slightly
different parameters.
PropMeasureHeight(Value,Canvas,AHeight)
This is called during the item/property height calculation phase of the
object inspectors rows render. This is very similar to TListBox's
OnMeasureItem, just slightly different parameters.
PropDrawName(Canvas,Rect,Selected)
Called during the render of the name column of the property list. Its
functionality is very similar to TListBox's OnDrawItem,but once again
it has slightly different parameters.
PropDrawValue(Canvas,Rect,Selected)
Called during the render of the value column of the property list. Its
functionality is similar to PropDrawName. If multiple items are selected
and their values don't match this procedure will be passed an empty
value.

Properties and methods useful in creating new TPropertyEditor classes:

Name property
Returns the name of the property returned by GetName
PrivateEditory property
This is the configuration directory of lazarus.
If the property editor needs auxiliary or state files (templates,
examples, etc) they should be stored in this editory.
Value property
The current value,as a string,of the property as returned by GetValue.
Modified
Called to indicate the value of the property has been modified. Called
automatically by the SetXxxValue methods. If you call a TProperty
SetXxxValue method directly,you *must* call Modified as well.
GetXxxValue
Gets the value of the first property in the Properties property. Calls
the appropriate TProperty GetXxxValue method to retrieve the value.
SetXxxValue
Sets the value of all the properties in the Properties property. Calls
the approprate TProperty SetXxxxValue methods to set the value.
GetVisualValue
This function will return the displayable value of the property. If
only one item is selected or all the multi-selected items have the same
property value then this function will return the actual property value.
Otherwise this function will return an empty string.}


ich möchte a: einenen eigenen eigenschafst editor einbinden
b: ich möchte den vorhanden nutzen können also auf load klicken und soweiter !

vielen dank im vorraus !

Edit:
das habe ich in der unit PropEdits wo noch mehr tolle sachen sind... mal sehen, wenn ich mir denn qullcode lange genug ansehe könnte ich evlt. ne idee bekommen wie das gehen könnte !
MFG
Michael Springwald

schnullerbacke
Beiträge: 1187
Registriert: Mi 13. Dez 2006, 10:58
OS, Lazarus, FPC: Winux (L 1.2.xy FPC 2.6.z)
CPU-Target: AMD A4-6400 APU
Wohnort: Hamburg

Beitrag von schnullerbacke »

Delphu kennst Du ja nun, das ist bei lazarus auch kaum anders. Geh mal davon aus, das lle einfachen Type (integer, boolean, string,..., sets) bereits über einen registrierten PropertyEditor verfügen. TTIPropertyGrid wird also alle bekannten Typen, die über einen PorpertyEditor verfügen auch richtig anzeigen.

Die Methodik, propertys aus dem Elternobjekt im Kindobjekt published zu machen funktioniert auch in Delphi nicht anders. Mit dem Unterschied, das man sowas elegantes wie TTIPropertyGrid da nicht standardmäßig hatte.

Du kannst dir also ohne größere Probleme einen eigenen OI bauen indem du einfach ein Formular nimmst und da ein TTreeView (TVirtualTreeView) oben draufsetzt und darunter ein TTIPropertyGrid.

Das Problem ist da eher, an die Z-Ordnung des bearbeiteten Formulars ranzukommen. Ich vermute mal das geht in lazarus ähnlich wie in Delphi mit:


Code: Alles auswählen

for i:= 0 to AktiveForm.ComponentCount - 1 do begin
  // Hier den TreeView updaten
end;



Solange die Komponenten öffentlich bekannt sind kannst mit Klicken im TreeView auf die entsprechende Komponente diese holen und dem PropertyGrid als verbundene Komponente übergeben. Das muß auch bei einer neuen Klasse klappen, die von einer bekannten Klasse abgeleitet ist. Das wird aber nur gehen, wenn die Elternklasse Streamfähig ist. D.h., sie muß ihre Eigenschaftsdaten auch von einer lfm-Datei lesen können. Bei nichtvisuellen Komponenten, wie eben TBitmap, wird das nicht unbedingt der Fall sein. Ein abgeleitetes Objekt muß diese Fähigkeit dann selbst hinzufügen, auch das war bei Delphi schon so.

Du darfst nich vergessen, das TBitmap, TCanvas und ähnliche nichtvisuelle Objekte einen Container darstellen. Die brauchen schon deshalb auch keine Sichtbarkeit, weil das ändern der Propertys auch nicht wirklich ein sichtbasres Ergebnis zeitigen können. Du mußt in solch einem Fall ein Objekt bauen, das visuell ist und in das TBitmap eingebettet ist. Das könnte z.B. TPanel, TScrollBox oder ähnlich sein.

Die Kombination TPanel mit TImage auf dem Panel würde Sinn machen. Da TImage schon über die Fähigkeit eine Image-Datei zu laden verfügt kann man diese Fähigkeit auch im eigenen Objekt sichtbar machen.

In Delphi ging das so:

Code: Alles auswählen

type
 
   TMyClass = class(TPanel)
   private
     FPicture: TPicture;
 
     function GetPicture: TPicture;
     procedure SetPicture(Value: TPicture);
   public
      constructor Create;
   published
      property Picture: TPicture read GetPicture write SetPicture;
    end;
 
implementation
 
function TMyClass.GetPicture: TPicture;
begin
   Result:= FImage.Picture;
end;
 
procedure TMyClass.SetPicture(Value: TPicture);
begin
   if (Value <> FImage.Picture) then FImage.Picture:= Value;
end;



Auf diese Weise greift Dein eigenes Objekt auf den Eigenschafts-Editor von dem eingebetteten Objekt TImage.Picture zu und bekommst den Lade-Dialog angezeigt. Das passiert sozusagen durch die Hintertür und du hast das Freihaus ohne großen Aufwand. Um TBitmap brauchst Du dich dann garnicht kümmern, das übernimmt im Beispiel FImage für dich.

Das geht also einfacher als gedacht, dein Elternobjekt mußt du halt nur geschickt wählen, dann geht das eigentlich ganz easy.

pluto
Lazarusforum e. V.
Beiträge: 7178
Registriert: So 19. Nov 2006, 12:06
OS, Lazarus, FPC: Linux Mint 19.3
CPU-Target: AMD
Wohnort: Oldenburg(Oldenburg)

Beitrag von pluto »

Code: Alles auswählen

unit uextras;
 
{$mode objfpc}{$H+}
 
interface
 
uses
  LCLIntf,  SysUtils, Classes, Graphics, Controls, Forms,
  Dialogs, ExtCtrls,StdCtrls,upaint2ObjBase,uPaint2Object;
 
type
 
  { tImageListB }
 
  TmyImage = class(Tpanel)
  private
    FPicture: TPicture;
    fImage:TImage;
 
    function GetPicture: TPicture;
    procedure SetPicture(Value: TPicture);
  public
//    constructor Create;
  published
    property Picture: TPicture read GetPicture write SetPicture;
  end;
 
  tImageListB = class(TPaint2Object)
  public
    constructor Create;
  private
    fpx,fpy,fsx,fsy:Integer;
    fmyimage:TmyImage;
 
//    function getImage: TBitmap;
//    procedure setImage(const AValue: TBitmap);
 
    procedure SetIndex(index,value:Integer);
    function GetIndex(index:Integer):integer;
 
  published
 
    property PX:Integer index 1 read getIndex write SetIndex;
    property PY:Integer index 2 read getIndex write SetIndex;
    property SX:Integer index 3 read getIndex write SetIndex;
    property SY:Integer index 4 read getIndex write SetIndex;
    property Image:TmyImage read fmyimage write fmyimage;
  end;
 
implementation
 
constructor tImagelistB.Create;
begin
  inherited Create;
 
  Name:='ImagelistB';
//  fimage:=TBitmap.Create;
    fmyimage:=TmyImage.Create(Screen.ActiveForm);
 
end;
 
procedure tImagelistb.SetIndex(index,value:Integer);
begin
  if index = 1 then fpx:=Value;
  if index = 2 then fpy:=Value;
  if index = 3 then fsx:=Value;
  if index = 4 then fsy:=Value;
end;
 
function tImagelistb.GetIndex(index:Integer):integer;
begin
  if index = 1 then result:=fpx;
  if index = 2 then result:=fpy;
  if index = 3 then result:=fsx;
  if index = 4 then result:=fsy;
end;
 
function TmyImage.GetPicture: TPicture;
begin
   Result:= fImage.Picture;
end;
 
procedure TmyImage.SetPicture(Value: TPicture);
begin
//   if (Value <> FImage.Picture) then
    FImage.Picture:= Value;
end;
 
end.

jetzt habe ich dort eine combobox bei Image... ich habe das problem das alle objekt von einem bestimmten object abgeleitet werden müssen nämlich von TPaint2Object da sie sonst nicht verarbeitet werden können... und mehrfach vererbungen gehen leider noch nicht.... habe ich versucht !
MFG
Michael Springwald

schnullerbacke
Beiträge: 1187
Registriert: Mi 13. Dez 2006, 10:58
OS, Lazarus, FPC: Winux (L 1.2.xy FPC 2.6.z)
CPU-Target: AMD A4-6400 APU
Wohnort: Hamburg

Beitrag von schnullerbacke »

@pluto

So, nun rätsel ich mal. Dein TPaint2Objekt soll wohl so eine Art Listen-Eintrag sein, der bestimmte Angaben über das Image enthalten soll (Größe usw.)?

Das willst Du dann benutzen und den TreeView einbauen?

Na meine Güte, das ist doch nun ganz einfach. Da baut man sich was ganz einfaches:

Code: Alles auswählen

TImageListEntry = class(TObject)
  // hier die Daten deklarieren und die propertys angeben
end;


Dann baust Du dir in TMyImage einfach ein:

FMyImageEntrys: TList;

Unterscheiden wird man die Teile wohl nach dem Image-Typ (bmp, xpm...), das bei TImageListEntry mit rein.

Nun kannst du mit dem selbgebauten Dialog TMyImage beliebig irgendwelche Images laden und dann entscheiden ob sie in die Liste sollen. Wenn das ja, dann erzeugst Du einen TTreeView-Eintrag und addierst den den zu TReeView und peng, das wars.

Zum ermitteln der Größe kann das Ding kurzfristig mit TBitmap.LoadFromFile kurzfristig in ein TBitmap laden und dessen Gröe auslesen und dann TBitmap.Free aufrufen und schon hat man auch das speicherschonend im Sacke.

Wenn sich TImageListEntry auch noch den Filename mit kompletten Pfad merkt kann man blitzartig darauf zugreifen. Wenn das Dann in TMyImage geladen ist, hast du vorher hoffentlich FImage mit TTIPropertyGrid verbunden und er zeigt dir alle relebanten Daten an.

Ohne viel Aufwand.

pluto
Lazarusforum e. V.
Beiträge: 7178
Registriert: So 19. Nov 2006, 12:06
OS, Lazarus, FPC: Linux Mint 19.3
CPU-Target: AMD
Wohnort: Oldenburg(Oldenburg)

Beitrag von pluto »

ich glaube da habe ich dich gestern wohl falsch verstanden:
Einen eigenen OI hatte ich schon mit hilfe der VST aufgebaut.
Doch leider funktiniert er nicht mehr unter Lazarus.
Darum habe ich komponenten von lazarus genommen.
und das TPaint2OBJ hat nur eine eigenschaft: property name:string.....
und auch nur eine aufgabue:
ich habe objekte die auf einer paintbox verschoben werden können und jetzt objekte die in einer extra liste kommen und nicht verschoben werden werden können.... wie z.b. diese imagelist(im momet das einzigste).

und wie gesagt einen eigenen hatte ich schon.... aber leider kann die normale TreeView keine spalten anzeigen(habe ich recht) und die TreeView kann kein baum anzeigen.

also habe ich nur zwei möglichkeiten:
1: ich finde den fehler in der VST
2: ich finde die ursache für die Zugriefsverletzung vom OI......
mehr möglichkeiten habe ich meiner meinung leider nicht !
MFG
Michael Springwald

schnullerbacke
Beiträge: 1187
Registriert: Mi 13. Dez 2006, 10:58
OS, Lazarus, FPC: Winux (L 1.2.xy FPC 2.6.z)
CPU-Target: AMD A4-6400 APU
Wohnort: Hamburg

Beitrag von schnullerbacke »

@pluto

Access Violation deutet meistens auf einen nicht initialisierten pointer hin. Meisten kommt da noch den Adressangabe, etwa:

$f0000000000000000000000000

so wars jedenfalls bei Delphi. Aber bei AV (Access violation) ist meistens ein pointer auf nil, das kann auch ein Objekt sein, auch das sind nur Zeiger. Das ließe sich mit F7 rauskriegen. Nimm dir die Konstruktoren von deinen Objekten vor und setz da nen Breakpoint hinter dem begin rein.

Meistens vergißt man dort einfach das Dummy-Objekt zu erzeugen. Wenns das nicht ist, dann gilt:

Wenn das Programm ohne Probleme startet, dann ist das in einer ausführenden Prozedur zu suchen, also ein Klickevent kommt da in Frage. Geht die Schritt für Schritt durch und guck dir die Inhalte von den Objekt-Dummys an.

Steht da sowas wie: $fb00e0

dann ist das ok, sonst steht da nilo oder: $00000

Dann wird das der Übeltäter sein. Da fehlt dann einfach:

MyTempObj:= TThisClass.Create;
Humor ist der Knopf, der verhindert, daß uns der Kragen platzt.

(Ringelnatz)

pluto
Lazarusforum e. V.
Beiträge: 7178
Registriert: So 19. Nov 2006, 12:06
OS, Lazarus, FPC: Linux Mint 19.3
CPU-Target: AMD
Wohnort: Oldenburg(Oldenburg)

Beitrag von pluto »

ich komme einfach nicht weiter...
unter windows konnte ich dank den debugger(den habe ich leider unter linux nicht)
herrausfinden welches dialog aufgerufen wird... wenn auf das ... neben Picture geklickt wird.
leider bringt mich das nicht weiter.
Da für jede betribsystem version eine andre ppu datei gibt.
die datei heißt:
GraphicPropEdit
sie wird von:
GraphPropEdits auf gerufen
.... evlt. bringt es euch ja weiter....
ich komme da einfach nicht mehr weiter....
habe auch keine idee wie ich den fehler noch ausfindig machen sollte

PS: den text habe ich unter windows geschrieben und abgespeichert und mit cat in der console wieder ausgeben !
MFG
Michael Springwald

schnullerbacke
Beiträge: 1187
Registriert: Mi 13. Dez 2006, 10:58
OS, Lazarus, FPC: Winux (L 1.2.xy FPC 2.6.z)
CPU-Target: AMD A4-6400 APU
Wohnort: Hamburg

Beitrag von schnullerbacke »

@pluto

Nanü? Kann das sein, daß das an deinem LINUX liegt? Ich hab openSuSE 10.0 laufen, da ist der gdb dabei. Das kann bei dir natürlich anders sein. Wenn man den Bei Eintellungen-->Debugger-Einstellungen festlegt (mit Pfad, /usr/bin/gdb) dann funzt der auch.

Wenn bei deinem Linux allerdings der ganze Etwicklungskram fehlt, dann wird das auch nicht gehen. Ich würde mal die openSuSE 10.0 als iso runterladen und brennen(braucht aber schon ne DVD). Dann haste keine Probleme mehr.
Humor ist der Knopf, der verhindert, daß uns der Kragen platzt.

(Ringelnatz)

pluto
Lazarusforum e. V.
Beiträge: 7178
Registriert: So 19. Nov 2006, 12:06
OS, Lazarus, FPC: Linux Mint 19.3
CPU-Target: AMD
Wohnort: Oldenburg(Oldenburg)

Beitrag von pluto »

vielen dank.. für den tip... ich teste es doch lieber unter windows da habe ich einen debugger...
und unter linux habe ich den halt nicht.. aber bringt mich leider auch nicht weiter
egal was ich auch mache immer kommt die AV !
MFG
Michael Springwald

pluto
Lazarusforum e. V.
Beiträge: 7178
Registriert: So 19. Nov 2006, 12:06
OS, Lazarus, FPC: Linux Mint 19.3
CPU-Target: AMD
Wohnort: Oldenburg(Oldenburg)

Beitrag von pluto »

ich habe es jetzt nach entlichen tagen zum laufen gebracht...
ihr müst einach zwei ereignise einen wert zuweisen.
es ist wohl ein bug bei den dialogen das sie das nicht prüfen ob dieses ereginsie gebracht werden oder nicht.
ich habe es bei mir so gelöst:

Code: Alles auswählen

procedure TForm1.FormCreate(Sender: TObject);
begin
   InitIDEFileDialog:=test;
   StoreIDEFileDialog:=test;
end;
// und test ist so defniert:
 
procedure TForm1.test(AFileDialog: TFileDialog);
begin
// ich so kann das dialog bestimmt geändert werden
// aber das ist mir im moment egal.
// ich meine damit das ihr hier afile Dialog mit sicherheit eure
// eigenies dialog einfügen könnt
end;


das ist das tolle an lazarus das die qullcode vorhanden sind !
in delphi hätte ich das problem noch nicht gelöst !

ich werde aufjedenfall bei lazarus bleiben... egal wie viel mühe es mich auch kosten mag mich an diese neue umgebung zu gewönen

aber das eigetnliche problem wie ich die variabeln die im OI angezeigt werden updaten kann weiß ich immer noch nicht !.

damit meine ich folgendes:
ich habe eine paintbox drauf zeichne ich mehre viereck(z.b.) die verschiebe ich jetzt mit der maus(das geht auch schon prima) und dann möchte ich gerne das sich die positions eigenschaft im oi ständig updaten also anpassen das gleiche soll mit der größe passiern.
MFG
Michael Springwald

schnullerbacke
Beiträge: 1187
Registriert: Mi 13. Dez 2006, 10:58
OS, Lazarus, FPC: Winux (L 1.2.xy FPC 2.6.z)
CPU-Target: AMD A4-6400 APU
Wohnort: Hamburg

Beitrag von schnullerbacke »

Dann mußt Du deine Vierecke zu eigenen Objekten machen und die entsprechenden Werte als property unter published angeben. Die richtige Vaterklasse ist aber wichtig, die muß Streamingfähig sein, dann werden die Werte auch im PropertyGrid ausgegeben. Du mußt halt, wenn du die anklickst, dafür sorgen, das die zum verbundenen Objekt im Grid werden. Dann geht das auch.
Humor ist der Knopf, der verhindert, daß uns der Kragen platzt.

(Ringelnatz)

pluto
Lazarusforum e. V.
Beiträge: 7178
Registriert: So 19. Nov 2006, 12:06
OS, Lazarus, FPC: Linux Mint 19.3
CPU-Target: AMD
Wohnort: Oldenburg(Oldenburg)

Beitrag von pluto »

das habe ich ja schon: alle vierecke sind von typ TPaintObject und dann habe ich noch TPaint2Obj das spieglt die bases klasse für alle objekte wieder....
das problem ist halt nur ich muss die daten im OI updaten und das bekomme ich einfach nicht hin !
MFG
Michael Springwald

Antworten