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

DBGrid с поддержкой Unicode   Найти похожие ветки 

 
Alexander   (2008-06-10 12:30) [0]

Подскажите пожалуйста DBGrid с поддержкой Unicode и возможностью раскрашивать в ячейках отдельные слова. Заранее благодарен


 
ЮЮ ©   (2008-06-10 12:39) [1]

Если в нем не редактировать, то любой. Только код рисования придется писать самому в OnDraw&#133


 
Anatoly Podgoretsky ©   (2008-06-10 13:10) [2]

> Alexander  (10.06.2008 12:30:00)  [0]

Вряд ли такие существуют в природе.


 
Правильный_Вася   (2008-06-10 13:43) [3]

в tnt unicode components смотрел?

раскраска - слишком простая вещь, чтобы в компонент ее пихать


 
zensan ©   (2008-06-11 08:40) [4]

Можешь мой пример попробовать...

procedure TCommon.DrawUnicodeCell(Sender: TObject; Column: TColumn;
 Rect: TRect);
var
 R: TRect;
 f: Widestring;
 Al: Integer;
begin
 R := Rect;
 R.Top := R.Top + 2;
 R.Bottom := R.Bottom - 2;
 R.Left := R.Left + 2;
 R.Right := R.Right - 2;
 f := WideStringReplace(Column.Field.AsWideString, "&", "&&",
   [rfReplaceAll]);
 case Column.Field.Alignment of
   taLeftJustify: Al := DT_LEFT;
   taRightJustify: Al := DT_RIGHT;
 else
   Al := DT_CENTER;
 end;
 DrawTextW(TJvDBGrid(Sender).Canvas.Handle, PWideChar(f), Length(f), R, Al);
end;

procedure TCommon.DefaultGridDrawColumnCell(Sender: TObject; const Rect: TRect;
 DataCol: Integer; Column: TColumn; State: TGridDrawState);
begin
 if Assigned(Column) then
   if Assigned(Column.Field) then
     if (Column.Field is TTntStringField) or
       (Column.Field is TAgoraTextLargeintField) then
       if not Column.Field.IsNull then
         begin
           DrawUnicodeCell(Sender, Column, Rect);
           Exit;
         end;
 TJvDBGrid(Sender).DefaultDrawColumnCell(Rect, DataCol, Column, State);
end;


 
zensan ©   (2008-06-11 08:47) [5]

Или просто TTntDBGrid...  и как мастера говорят "самому раскрашивать.."


 
Alexander   (2008-06-11 11:06) [6]

спасибо!


 
Prohodil Mimo ©   (2008-06-13 01:05) [7]

так можно и в обычном гриде, только всё самому рисовать.



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

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



Память: 0.46 MB
Время: 0.032 c
15-1213004432
LightRipple
2008-06-09 13:40
2008.07.27
Коварный inline :)


15-1212761210
Ega23
2008-06-06 18:06
2008.07.27
Не дать организьму умереть от обезвоживания?


2-1214392234
Res
2008-06-25 15:10
2008.07.27
wininet


15-1213126413
wl
2008-06-10 23:33
2008.07.27
oracle getting started


15-1213095081
Res
2008-06-10 14:51
2008.07.27
текст с картинки




   Наверх