Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2008.07.27;
Скачать: 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 вся ветка

Текущий архив: 2008.07.27;
Скачать: CL | DM;

Наверх




Память: 0.48 MB
Время: 0.017 c
15-1212718745
brother
2008-06-06 06:19
2008.07.27
посоветуйте монитор...


1-1195679272
Евгений Р.
2007-11-22 00:07
2008.07.27
Максимальный размер tStringList


15-1212840446
Vlad Oshin
2008-06-07 16:07
2008.07.27
как работает и почему такой ответ


11-1191046802
Vladimir Kladov
2007-09-29 10:20
2008.07.27
Версия 2.81


2-1214382141
Jimmy
2008-06-25 12:22
2008.07.27
RunTimeError 216