Autor Beitrag
G-McKree
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Fr 06.06.03 19:05 
Ich brauch nen Record, der alle Eigenschaften von TImage und ein paar weitere hat. Hab aber null Ahnung, wie ich das anstellen soll.


Zuletzt bearbeitet von G-McKree am Mo 09.06.03 21:35, insgesamt 1-mal bearbeitet
G-McKree Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Sa 07.06.03 15:44 
oder gibt es ne möglichkeit nem TImage ein paar neue 'property's anzuhängen?
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Sa 07.06.03 15:48 
Du könntest Deine eigene Klasse von TImage ableiten, dann kannst Du da Eigenschaften hinzufügen, wie Du lustig bist.

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".
G-McKree Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Sa 07.06.03 15:49 
Peter Lustig hat folgendes geschrieben:
Du könntest Deine eigene Klasse von TImage ableiten, dann kannst Du da Eigenschaften hinzufügen, wie Du lustig bist.

genau so was mein ich, hab aber keine ahnung, wie das geht
Motzi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 2931

XP Prof, Vista Business
D6, D2k5-D2k7 je Prof
BeitragVerfasst: Sa 07.06.03 15:52 
Dann wirds Zeit sich mal mit OOP zu beschäftigen! :)
Schau dir vielleicht mal meine Ausarbeitung zu OOP in Delphi an: www.x-spy.net/personal

_________________
gringo pussy cats - eef i see you i will pull your tail out by eets roots!
G-McKree Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Sa 07.06.03 16:06 
Motzi hat folgendes geschrieben:
Dann wirds Zeit sich mal mit OOP zu beschäftigen! :)
Schau dir vielleicht mal meine Ausarbeitung zu OOP in Delphi an: www.x-spy.net/personal


dein tutorail is zwar schön, aber könnte mehr source drin sein, ich weiss jez nämlich nich, wo ich das deklarieren soll

wie wärs mit etwas source?
G-McKree Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Sa 07.06.03 16:08 
P.S. was is diese ungarische notation?
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Sa 07.06.03 16:09 
Tja, eigentlich wollte ich jetzt wieder auf ein Delphi-Source-Tutorial verweisen, aber nachdem ich Motzis Abahndlung überflogen habe, denke ich, kann das Tutorial bei Delphi-Source nicht besser sein. Super Arbeit! Respekt!

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Sa 07.06.03 16:12 
@G-McKree Motzis Abhandlung anscheinend nicht zu schätzen weis, hier noch ein Link nach Delphi-Source. Aber wie gesagt: bei Motzis Text bekommst das Wissen mit den bei OOP sehr wichtigen Grundlagen vermittelt.

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".
G-McKree Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Sa 07.06.03 16:15 
ich hab jez ne class, aber delphi will deren eigenschaften nicht akzeptieren

ausblenden Quelltext
1:
2:
3:
4:
5:
6:
7:
type
  TQuad = class(TImage)
   property Left: boolean;
   property Right: boolean;
   property Up: boolean;
   property Down: boolean;
   property Typ: integer;
Motzi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 2931

XP Prof, Vista Business
D6, D2k5-D2k7 je Prof
BeitragVerfasst: Sa 07.06.03 18:19 
@Peter Lustig: danke für das Lob! *freu* :D 8)
Wie auch auf der Homepage steht war das ganze eine Ausarbeitung für meine Informatik-Abschlußprüfung (Matura) und daher eher theoretisch gehalten und mit weniger Source, aber dafür eben auch tiefergehender...

@G-McKree: die ungarische Notation ist eine "Standardisierung" für den Präfix bei der Namensgebung von Variablen o.ä.

Zu deiner Klasse: bein property muss man immer angeben wie diesen gelesen bzw gesetzt werden soll. Also entweder wird direkt auf das private Feld zugegriffen oder aber du verwendest Lese- oder Schreib-Methoden.

_________________
gringo pussy cats - eef i see you i will pull your tail out by eets roots!
Luckie
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Sa 07.06.03 19:47 
Auf meiner Seite: www.luckie-online.de findest du bei den Tutorials auch einen kleinen Text über OOPP und Klassen mit Delphi.

@Motzi: Kann ich dich da zu den weiterführenden Links hinzufügen?
Motzi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 2931

XP Prof, Vista Business
D6, D2k5-D2k7 je Prof
BeitragVerfasst: Sa 07.06.03 20:04 
Luckie hat folgendes geschrieben:
@Motzi: Kann ich dich da zu den weiterführenden Links hinzufügen?

Natürlich kannst du! Und du darfst auch, soll heißen ich erlaubs dir! ;)

_________________
gringo pussy cats - eef i see you i will pull your tail out by eets roots!
G-McKree Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Mo 09.06.03 20:42 
also wie ich jez meine proertys zum laufen kriege, ham ich net geschnallt
Christian S.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 20451
Erhaltene Danke: 2264

Win 10
C# (VS 2019)
BeitragVerfasst: Mo 09.06.03 20:46 
Du darfst uns Deine Probleme auch ausführlicher beschreiben! Sprich Dich aus, wir sind alle Deine Freunde!

_________________
Zwei Worte werden Dir im Leben viele Türen öffnen - "ziehen" und "drücken".
Luckie
Ehemaliges Mitglied
Erhaltene Danke: 1



BeitragVerfasst: Mo 09.06.03 20:52 
Das ist wie bei der Beichte oder beim Arzt hier: Wir unterliegen alle hier der Schweigeflicht.

Und bitte verwende nur Wörter, die man entweder im Duden, im Fremdwörterbuch oder wenn es Fachwörter sind im Englisch Wörterbuch findet. In keiner der angegebenen Quellen konnte ich das Wort "proertys" finden.
Tweafis
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 647

WinXP + fbsd
Delphi 5 Prof
BeitragVerfasst: Mo 09.06.03 20:56 
Wenn mich nicht alles täuscht meinte er propertys ;)

_________________
.: Es wird der Tag kommen, an dem wir es nicht mehr ändern können :.
ErnestoChe
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 528

Win 2000 pro, CRUX 2.0
Delphi 6 Pers, Open K3
BeitragVerfasst: Mo 09.06.03 21:03 
Tweafis hat folgendes geschrieben:
Wenn mich nicht alles täuscht meinte er propertys


Das heisst properties :wink: :wink:
Tweafis
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 647

WinXP + fbsd
Delphi 5 Prof
BeitragVerfasst: Mo 09.06.03 21:08 
English 6, setzen (@me)

Stimmt ja, aus y wird bei plural ie außer wenn vor dem y ein Vokal steht wie z.B. boys.

So, zählt das als wiedergutmachung? :mrgreen:

_________________
.: Es wird der Tag kommen, an dem wir es nicht mehr ändern können :.
G-McKree Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 178



BeitragVerfasst: Mo 09.06.03 21:16 
ausblenden Quelltext
1:
2:
type
  TQuad = class(TImage)


das funzt

aber ich brauch noch ne ''property typ: integer'' und weiss nich wie ich die deklarieren soll