Jump to content

Recommended Posts

Posted

Hi Fenix,

 

 

It could actually be an "imagelist". Or a button as follows. How can I access these pictures? (fa_phone, fa_photo, ...)

 

https://www.w3schools.com/bootstrap/bootstrap_dropdowns.asp

 

Other question, How to change the icon with code?

 

procedure TFAgent.ACW1Click(Sender: TObject);
begin
btnDurum.ButtonStyles:=bs_warning;//<-- No problem
btnDurum.IconFont:=fa_folder_open;//<-- Don't change
end;
Best regards
Posted

Hi multimesut,

 

 

It could actually be an "imagelist". Or a button as follows. How can I access these pictures? (fa_phone, fa_photo, ...)

This is a font, not a saved image. Reference http://fontawesome.io/

 

Other question, How to change the icon with code?

According to the message I sent you, please update your version.
 
 
Any questions, let me know.
 
Best regards
Posted
Hi multimesut,

 

These options are new, then I will review and add in a next update if there is no conflict with unigui.

I'll return as soon as I test.

 

Best regards

Posted

Thank you Fenix. I've been trying the following code. Its Work.

swal({
  title: 'Aktarılacak numarayı giriniz',
  input: 'text',
  showCancelButton: true,
  confirmButtonText: 'Aktar',
  cancelButtonText: 'İptal',
  showLoaderOnConfirm: true,
  preConfirm: function (number) {
    return new Promise(function (resolve, reject) {
		if (isNaN(number)) {
			reject('Sadece rakam girebilirsiniz!')
		} else {
			//mycode
			resolve()
		}
    })
  },
  allowOutsideClick: false
}).then(function (number) {
  swal({
    type: 'success',
    title: 'Aktarma İşlemi Başarılı',
    html: 'Aktarılan numara: ' + number
  })
})
Posted

Hi multimesut,

 

So, appearing is easy, the problem is how it will recover the data later and I always try to leave it in a simple way by the component.

 

Best regards

  • 4 weeks later...
Posted

Hi Fenix , 

 

Your SFComponents are really looking good to build Unigui App .

I guess you are good at  Bootstrap dealing with Unigui components .

It would be better if you could support  such as a FloatingPanel component with Bootstrap.( i don't know the name  exactly )

 

For example , On desktop , Bootstrap shows all panels as much as it can show as full screen  and

On mobile when it is resizing as smaller size , All panels are re-arranged again and fitted again along with the width of screen size.

 

If you can support it , i will be able to be one of your members . 

 

Best regards,

Posted

Hi David,

 

Thanks for the sugestion.
I do not use the javascript library from the bootstrap, the risk of having conflict is high.
Soon I'll be adding new components to the library and I'll study if that's possible.
 
Best regards
  • 2 weeks later...
Posted

Hi

 

How can i add other button languages to the SweetAlert. Is there a file which contains
the translation or do i have the edit the UniSFSweetAlert

 

I can change the Portugese value for Yes and No into the value for dutch

but when selecting the language for the component i can choose from

English and Potugese.

 

And is itpossible to make the buttons same size/length

 

Regards Peter

  • 1 month later...
Posted

Hi,

 
We recently bought your components UniSF. It's an issue with it. I try to create TUniSFBitBtn dynamically, but I can't do it.
 
I try to do it with this code:
procedure TMainForm.UniFormCreate(Sender: TObject);
var
  UniSFBitBtn2: TUniSFBitBtn;
begin
  UniSFBitBtn2 := TUniSFBitBtn(InsertControl(TUniSFBitBtn.Create(Self)));

  UniSFBitBtn2.Name := 'UniSFBitBtn2';
  UniSFBitBtn2.Parent := Self;
  UniSFBitBtn2.Left := 64;
  UniSFBitBtn2.Top := 231;
  UniSFBitBtn2.Width := 113;
  UniSFBitBtn2.Height := 121;
  UniSFBitBtn2.Hint := '';
  UniSFBitBtn2.Caption := 'Dr. Mohammad';
  UniSFBitBtn2.TabOrder := 1;
  UniSFBitBtn2.ClientEvents.UniEvents.Add('beforeInit=function(sender, config){ sender.action = '#39'badgetext'#39);
  UniSFBitBtn2.ClientEvents.UniEvents.Add('; sender.plugins = [{  ptype:'#39'badgetext'#39',  defaultText: 0,  disa');
  UniSFBitBtn2.ClientEvents.UniEvents.Add('bleOpacity:1,  disableBg:'#39'red'#39',  align:'#39'right'#39' }];}');
  UniSFBitBtn2.IconAlign := TUniIconAlign.iaTop;
  UniSFBitBtn2.IconFont := fa_lock;
  UniSFBitBtn2.IconFontColor := fc_white;
  UniSFBitBtn2.IconFontSize := fs_48;
  UniSFBitBtn2.ButtonStyles := bs_info;
end;
And my test app doesn't started. I discovered, that problem is with this strings of code:
  UniSFBitBtn2.ClientEvents.UniEvents.Add('beforeInit=function(sender, config){ sender.action = '#39'badgetext'#39);
  UniSFBitBtn2.ClientEvents.UniEvents.Add('; sender.plugins = [{  ptype:'#39'badgetext'#39',  defaultText: 0,  disa');

When i remove they, all starts good, but button shows improperly.

 
If I add button not on main form, app starts. But when test form opened error is shown:
 
Ajax error
 
 O18D=new Ext.window.Window({id:"O18D_id",retfalse:{},onEsc:Ext.emptyFn,layout:"fit",title:"test window",resizable:false,maximizable:false,minimizable:false,uniFMask:{beforeclose:true},width:258,height:258,x:744,y:291});O18D.nm="O18D";_cdo_("UniForm27");UniForm27.ajxS=AjaxSuccess;UniForm27.ajxF=AjaxFailure;O18D.rootObj=true;UniForm27.appRoot="/";_cdo_(null,O18D,"window",UniForm27); O195=new Ext.form.Panel({id:"O195_id",border:false,tabItems:new Ext.util.MixedCollection(),layout:"absolute"});O195.nm="O195";_cdo_(null,O195,"form",UniForm27);O18D.add(O195); O19D= (function(P0){return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=beforeclose&this="+P0.nm+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"beforeclose"});});O19D.nm="O19D";O18D.on("beforeclose",O19D); O19E= (function(P0){_saf_(P0);return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=activate&this="+P0.nm+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"activate"});});O19E.nm="O19E";O18D.on("activate",O19E); O19F= (function(P0){return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=deactivate&this="+P0.nm+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"deactivate"});});O19F.nm="O19F";O18D.on("deactivate",O19F);O18D.on("deactivate",function(f){_sdf_(f)}); O1A0=new Ext.button.Button({id:"O1A0_id",text:"Dr. Mohammad",beforeinit:function(sender, config){ sender.action = 'badgetext',tabIndex:267,scale:"large",iconAlign:"top",iconCls:"x-uni-btn-icon-top",width:115,height:121,x:8,y:129});O1A0.nm="O1A0";_cdo_("UniSFBitBtn0",O1A0,null,UniForm27);_coxe_(UniForm27,"UniSFBitBtn0","; sender","plugins ", [{  ptype:'badgetext',  defaultText: 0,  disa);_coxe_(UniForm27,"UniSFBitBtn0",null,"",);O195.add(O1A0); O1A4= (function(P0,P1,P2){return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=resize&this="+P0.nm+"&w="+P1+"&h="+P2+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"resize"});});O1A4.nm="O1A4";O18D.on("resize",O1A4); O1A5= (function(P0,P1,P2){return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=move&this="+P0.nm+"&x="+P1+"&y="+P2+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"move"});});O1A5.nm="O1A5";O18D.on("move",O1A5); O1A6= (function(P0){return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=maximize&this="+P0.nm+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"maximize"});});O1A6.nm="O1A6";O18D.on("maximize",O1A6); O1A7= (function(P0){return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=minimize&this="+P0.nm+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"minimize"});});O1A7.nm="O1A7";O18D.on("minimize",O1A7); O1A8= (function(P0){return Ext.Ajax.request({url:"/HandleEvent",params:"Ajax=1&IsEvent=1&Obj=O18D&Evt=restore&this="+P0.nm+""+_gv_(O195),success:AjaxSuccess,failure:AjaxFailure,obj:O18D,e:"restore"});});O1A8.nm="O1A8";O18D.on("restore",O1A8);O18D.show("");O18D.retfalse.beforeclose=1;_axy_(O18D);O18D.uniMask={ldMask:false,maskWaitData:false,maskUseMsg:true};O18D.uniMask.targetObj=null;O1A0.addToTab(2670);
 
And form doesn't opens. The reason is same - two strings.
 
Is it possible to fix this issue? Thank you.
Posted

Hello, You can test;

procedure TMainForm.UniFormCreate(Sender: TObject);
var
  UniSFBitBtn2: TUniSFBitBtn;
  x: String;
begin
  UniSFBitBtn2 := TUniSFBitBtn(InsertControl(TUniSFBitBtn.Create(Self)));

  UniSFBitBtn2.Name := 'UniSFBitBtn2';
  UniSFBitBtn2.Parent := Self;
  UniSFBitBtn2.Left := 64;
  UniSFBitBtn2.Top := 231;
  UniSFBitBtn2.Width := 113;
  UniSFBitBtn2.Height := 121;
  UniSFBitBtn2.Hint := '';
  UniSFBitBtn2.Caption := 'Dr. Mohammad';
  UniSFBitBtn2.TabOrder := 1;
  x:='sender.action = '#39'badgetext'#39';';
  x:=x+'sender.plugins = [{  ptype:'#39'badgetext'#39',  defaultText: 0,  disableOpacity:1,';
  x:=x+'disableBg:'#39'red'#39',  align:'#39'right'#39' }];';
  UniSFBitBtn2.JSInterface.JSAddListener('beforeInit', UniSFBitBtn2.JSInterface.JSFunction('sender, config', x));
  //UniSFBitBtn2.ClientEvents.UniEvents.Add('beforeInit=function(sender, config){ sender.action = '#39'badgetext'#39);
  //UniSFBitBtn2.ClientEvents.UniEvents.Add('; sender.plugins = [{  ptype:'#39'badgetext'#39',  defaultText: 0,  disa');
  //UniSFBitBtn2.ClientEvents.UniEvents.Add('bleOpacity:1,  disableBg:'#39'red'#39',  align:'#39'right'#39' }];}');
  UniSFBitBtn2.IconAlign := TUniIconAlign.iaTop;
  UniSFBitBtn2.IconFont := fa_lock;
  UniSFBitBtn2.IconFontColor := fc_white;
  UniSFBitBtn2.IconFontSize := fs_48;
  UniSFBitBtn2.ButtonStyles := bs_info;
end;
Posted

Hi, 

I will have to do a test, but I do not guarantee that this will work.
And I did not understand the need to add dynamically, being in the create do form.
 
Best regards
Posted

Hi,

Do you have any progress? We really need this function :)

 

Hi,

 

The component includes some commands to be able to change in runtime, the way it is doing conflicts, I have not found a way to keep the feature and allow the button to be included in runtime.

 

Best regards

Guest
This topic is now closed to further replies.
×
×
  • Create New...