Autor Beitrag
danielpt
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 81

Windows 2000 Professional SP4
D6 Personal
BeitragVerfasst: Sa 09.08.03 12:06 
Hallo!
Frage: Wie kann ich erstellen, dass nur der markierte Text z.B. kursiv wird?

Weil so
ausblenden Delphi-Quelltext
1:
 Richedit1.Font.Style :=[fsbold];					

wird der ganz Text immer fett, kursiv, etc...

_________________
cu daniel
Keldorn
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 2266
Erhaltene Danke: 4

Vista
D6 Prof, D 2005 Pro, D2007 Pro, DelphiXE2 Pro
BeitragVerfasst: Sa 09.08.03 13:20 
schau in der unter Richedit eigenschaft Suche in: Delphi-Forum, Delphi-Library SELATTRIBUTES nach. da ist auch ein Beispiel dabei.

Mfg Frank

Moderiert von user profile iconTino: DF-Tag hinzugefügt.

_________________
Lükes Grundlage der Programmierung: Es wird nicht funktionieren.
(Murphy)
danielpt Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 81

Windows 2000 Professional SP4
D6 Personal
BeitragVerfasst: Sa 09.08.03 17:16 
also, fett, kursiv und unterstrichen gehen...

Wie mach ich das ganz aber bei der Farbe?

Mein jetziger (das wird aber der ganze Text formatiert!):
ausblenden Delphi-Quelltext
1:
RichEdit1.Font.Color :=(JvColorButton2.Color);					


Bitte per Sourcecode antworten! thx!

_________________
cu daniel
Aya
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 1964
Erhaltene Danke: 15

MacOSX 10.6.7
Xcode / C++
BeitragVerfasst: Sa 09.08.03 18:19 
Hi,

ausblenden Delphi-Quelltext
1:
RichEdit1.SelAttributes.Color:=clYellow;					

Hättest du aber eigentlich ganz leicht durch einen blick in die DelphiHilfe rausbekommen können ;)

Au'revoir,
Aya~

_________________
Aya
I aim for my endless dreams and I know they will come true!
danielpt Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 81

Windows 2000 Professional SP4
D6 Personal
BeitragVerfasst: So 10.08.03 08:16 
Thx, aber ich denke so
ausblenden Delphi-Quelltext
1:
RichEdit1.SelAttributes.Color:=(JvColorButton2.Color);					

ist er richtiger...

_________________
cu daniel
Tino
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Veteran
Beiträge: 9839
Erhaltene Danke: 45

Windows 8.1
Delphi XE4
BeitragVerfasst: Mo 11.08.03 08:26 
danielpt hat folgendes geschrieben:
Thx, aber ich denke so [...] ist er richtiger...

Die Antwort von Aya ist schon richtig. Woher sollte Aya auch wissen das du diese TJvColorButton benutzt um die Farbe anzugeben.

Du kannst auch die Klammerung entfernen:
ausblenden Delphi-Quelltext
1:
RichEdit1.SelAttributes.Color:=JvColorButton2.Color;					


Gruß
Tino
danielpt Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 81

Windows 2000 Professional SP4
D6 Personal
BeitragVerfasst: Mo 11.08.03 13:13 
ja, danke Tino, aber meins geht auch, trotzdem danke!

_________________
cu daniel
Tino
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Veteran
Beiträge: 9839
Erhaltene Danke: 45

Windows 8.1
Delphi XE4
BeitragVerfasst: Di 12.08.03 10:38 
danielpt hat folgendes geschrieben:
aber meins geht auch!

Ich weiß... trotzdem ergeben die Klammern keinen Sinn :-D

Gruß
Tino