rtalmeida Posted October 30, 2017 Share Posted October 30, 2017 resize component in run time whit mouse is possible? have a example? Quote Link to comment Share on other sites More sharing options...
Sherzod Posted October 30, 2017 Share Posted October 30, 2017 Hi, Which component do you want to resize ? Quote Link to comment Share on other sites More sharing options...
rtalmeida Posted October 30, 2017 Author Share Posted October 30, 2017 UniEdit, UniMemo, UniNumberEdit, etc... Quote Link to comment Share on other sites More sharing options...
rtalmeida Posted October 31, 2017 Author Share Posted October 31, 2017 it's possible? Quote Link to comment Share on other sites More sharing options...
Sherzod Posted October 31, 2017 Share Posted October 31, 2017 Hi, it's possible? You can try this approach, but the compatibility is not fully tested, try For example for UniMemo: function added(sender, container, pos, eOpts) { sender.resizable = { minWidth: 160, minHeight: 120, dynamic: true, pinned: true, handles: 's e se', heightIncrement: 20, widthIncrement: 20 }; } Best regards, Quote Link to comment Share on other sites More sharing options...
rtalmeida Posted October 31, 2017 Author Share Posted October 31, 2017 worked perfect, once again thanks for your help Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 19, 2020 Share Posted January 19, 2020 Did not work for me v1.10.0.1472 What could it be? Quote Link to comment Share on other sites More sharing options...
Sherzod Posted January 19, 2020 Share Posted January 19, 2020 6 hours ago, herculanojs said: Did not work for me v1.10.0.1472 What could it be? Perhaps it is better to upgrade to the latest build!? Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 19, 2020 Share Posted January 19, 2020 I cannot update the version at this time Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 19, 2020 Share Posted January 19, 2020 some other solution Quote Link to comment Share on other sites More sharing options...
Sherzod Posted January 19, 2020 Share Posted January 19, 2020 7 hours ago, herculanojs said: Did not work for me v1.10.0.1472 What could it be? Can you make a simple testcase for check? Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 19, 2020 Share Posted January 19, 2020 1 minute ago, Sherzod said: Can you make a simple testcase for check? yes Project1.zip Quote Link to comment Share on other sites More sharing options...
Sherzod Posted January 19, 2020 Share Posted January 19, 2020 12 minutes ago, herculanojs said: Project1.zip I will check... Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 19, 2020 Share Posted January 19, 2020 thanks Quote Link to comment Share on other sites More sharing options...
Sherzod Posted January 21, 2020 Share Posted January 21, 2020 On 1/20/2020 at 12:28 AM, herculanojs said: yes Project1.zip For UniMemo: procedure TMainForm.UniFormCreate(Sender: TObject); begin with UniMemo1.JSInterface do JSAddListener('afterrender', 'function(){'+ 'this.initResizable({'+ ' minWidth: 100,'+ ' minHeight: 100'+ '}); '+ 'this.bodyEl.setStyle("width", "100%");'+ '}' ); end; 1 Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 21, 2020 Share Posted January 21, 2020 well, thank you Quote Link to comment Share on other sites More sharing options...
artem_niko Posted January 21, 2020 Share Posted January 21, 2020 6 hours ago, Sherzod said: For UniMemo: procedure TMainForm.UniFormCreate(Sender: TObject); begin with UniMemo1.JSInterface do JSAddListener('afterrender', 'function(){'+ 'this.initResizable({'+ ' minWidth: 100,'+ ' minHeight: 100'+ '}); '+ 'this.bodyEl.setStyle("width", "100%");'+ '}' ); end; Not working for UniEdit or UniButton, for example... Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 21, 2020 Share Posted January 21, 2020 Just now, Артем said: Not working for UniEdit or UniButton, for example... Tested in uniedit and working perfect with UniEdit1.JSInterface do JSAddListener('afterrender', 'function(){'+ 'this.initResizable({'+ ' minWidth: 100,'+ ' minHeight: 100'+ '}); '+ 'this.bodyEl.setStyle("width", "100%");'+ '}' ); Quote Link to comment Share on other sites More sharing options...
artem_niko Posted January 21, 2020 Share Posted January 21, 2020 2 minutes ago, herculanojs said: Tested in uniedit and working perfect with UniEdit1.JSInterface do JSAddListener('afterrender', 'function(){'+ 'this.initResizable({'+ ' minWidth: 100,'+ ' minHeight: 100'+ '}); '+ 'this.bodyEl.setStyle("width", "100%");'+ '}' ); May be this is because I using UniSFBitBtn (SF Components)? Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 21, 2020 Share Posted January 21, 2020 Just now, Артем said: May be this is because I using UniSFBitBtn (SF Components)? Understand. It could be something related to the component Quote Link to comment Share on other sites More sharing options...
artem_niko Posted January 21, 2020 Share Posted January 21, 2020 3 minutes ago, herculanojs said: Understand. It could be something related to the component https://app.fenixerp.com.br/unigui/ Quote Link to comment Share on other sites More sharing options...
herculanojs Posted January 21, 2020 Share Posted January 21, 2020 Just now, Артем said: https://app.fenixerp.com.br/unigui/ I think it would be interesting to exchange an idea with the developer of the components Quote Link to comment Share on other sites More sharing options...
eduardosuruagy Posted January 21, 2020 Share Posted January 21, 2020 how to enable and disable it by clicking a button? 15 hours ago, Sherzod said: For UniMemo: procedure TMainForm.UniFormCreate(Sender: TObject); begin with UniMemo1.JSInterface do JSAddListener('afterrender', 'function(){'+ 'this.initResizable({'+ ' minWidth: 100,'+ ' minHeight: 100'+ '}); '+ 'this.bodyEl.setStyle("width", "100%");'+ '}' ); end; Quote Link to comment Share on other sites More sharing options...
Sherzod Posted January 22, 2020 Share Posted January 22, 2020 6 hours ago, eduardosuruagy said: how to enable and disable it by clicking a button? Try this approach for example: Quote Link to comment Share on other sites More sharing options...
erich.wanker Posted February 21, 2020 Share Posted February 21, 2020 perfect :-) Thank you !!! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.