Вниз
Скачать: CL | DM;

Шрифт в ListBox е   Найти похожие ветки 

← →
Washington ©   (2007-10-30 15:02) [0]

Как сделать, чтобы при щелчке на ListBox"e шрифт выделенного элемента менялся?


← →
Джо ©   (2007-10-30 15:18) [1]

Style := lbOwnerDrawFixed

И в обработчике OnDrawItem:

begin
 with TListBox(Control).Canvas do
 begin
   if odSelected in State then
   begin
     Brush.Color := clActiveCaption;
     Font.Color := clHighlightText;
     Font.Name := "Arial"
   end
   else
   begin
     Brush.Color := clWindow;
     Font.Color := clWindowText;
     Font.Name := "Times New Roman"      
   end;
   ListBox1.Canvas. FillRect (Rect);

   TextOut(Rect.Left,Rect.Top,TListBox(Control).Items[Index]);
 end;
end;



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.44 MB
Время: 0.014 c
1-1189155493
dima_q
2007-09-07 12:58
2007.11.25
Локализация в Delphi


6-1174494739
Wolland
2007-03-21 19:32
2007.11.25
Использование TCPServer и TCPClient


2-1193694632
Nikola
2007-10-30 00:50
2007.11.25
Фильтры ADOTable


4-1179212932
tralala
2007-05-15 11:08
2007.11.25
Есть ли возможность отловить обрашение к реестру?


15-1192885708
к2в2
2007-10-20 17:08
2007.11.25
илюстратор + delphi




   Наверх