Jump to content

TUniPropertyGrid


Dm_Ufa

Recommended Posts

Здравствуйте,

Пожалуйста, уточните версию и издание UniGUI, которую Вы используете.

7 hours ago, Dm_Ufa said:

Почему при загрузке свойств TUniDBTreeGrid в UniPropertyGrid не видно свойство Align? И как можно исправит?

Простите, уточните вопрос.

Link to comment
Share on other sites

31 minutes ago, x11 said:

Если я правильно понял, то UniPropertyGrid не отображает свойство Align.

вот мне и интересно, почему. Я вроде разобрался как добавить, теперь проблема как добавить два редактора свойств. Мне при выборе, например, компонента uniDBEdit1, в PropertyGrid надо добавить свойства Align и DataSource. Делаю так:

        UniPropertyGrid1.AddProperty(['DataSource', TDataSource(GetObjectProp(c, 'DataSource')).Name]);

        UniPropertyGrid1.AddProperty(['Align', GetEnumName(TypeInfo(TAlign), Ord(TWinControl(c).Align))]);

add := #1'.sourceConfig = {DataSource: {editor: new Ext.grid.CellEditor({field: new Ext.form.field.ComboBox({editable: false, store:["None", "DS1", "DS2"]})})}};';' + #13 +

           #1'.sourceConfig = {Align: {editor: new Ext.grid.CellEditor({field: new Ext.form.field.ComboBox({editable: false, store:["alNone", "alTop", "alBottom", "alLeft", "alRight", "alClient", "alCustom"]})})}};';

        UniPropertyGrid1.JSInterface.JSCode(add);
        TExPGrid(UniPropertyGrid1).PopulateGrid;

 

При этом нормально работает только один редактор (Align), в свойстве DataSource просто имя TDataSource, т.е. нет списка.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...