Jump to content

Sherzod

Moderators
  • Posts

    19707
  • Joined

  • Last visited

  • Days Won

    637

Posts posted by Sherzod

  1. Ну, тема это как бы дополнительное расширение фреймворка, я бы сказал. uniGUI также включает в себя множество собственных тем.

    Сначала Вам необходимо приобрести лицензию на uniGUI, если вы хотите продолжать его использовать.

  2. 28 minutes ago, gerhardhziegler said:

    UniGui 1.50.0.1480, GoogleChrome , Win 8 to Win 11. D 2010 at the moment. triton.modified, Desktop.
    MainForm.Script is practically empty, the three lines are the the beginning.
    Maybe its possible to overrule somwhere in the calendar scripts itself?

    Can you test these codes on a demo example?

  3. 3 minutes ago, gerhardhziegler said:

    But it doesnt work.

    Sorry, this seems to have worked for me.

    4 minutes ago, gerhardhziegler said:

    Its still shown when I am clicking or rangeselecting.

    How can we reproduce this? Which browser are you using? Device (desktop, mobile) !?

  4. Let's add TrayClock to UniStatusBar (can be added to other controls).

    image.png.3aa181507df732f0bde729dc339978e3.png

    1. 

    initialization
      UniAddCSSLibrary('build/packages/ux/classic/classic/resources/ux-all.css', False, [upoFolderJS, upoPlatformDesktop]);
      UniAddJSLibrary('build/packages/ux/classic/ux.js', False, [upoFolderJS, upoPlatformDesktop]);

    2. UniStatusBar.ClientEvents.ExtEvents ->

    function afterrender(sender, eOpts) 
    {
        if (Ext.isDefined(Ext.ux)) {
            sender.add({
                xtype: 'tbfill'
            });
            sender.add(
                new Ext.ux.desktop.TrayClock()
            );
        }
    }

     

    Let's modify by adding a style, a time format, and an update time of one second.

    image.png.a567e0b40407234b04b882ed7e072e61.png

    (2).

    function afterrender(sender, eOpts) 
    {
        if (Ext.isDefined(Ext.ux)) {
            sender.add({
                xtype: 'tbfill'
            });
            sender.add(new Ext.ux.desktop.TrayClock({
                tpl: '<span style="color: green; font-weight: bold;">{time}</span>', //default = '{time}'
                timeFormat: 'Y-m-d H:i:s', //default = 'g:i A'
    
                updateTime: function() {
                    var me = this,
                        time = Ext.Date.format(new Date(), me.timeFormat),
                        text = me.tpl.apply({
                            time: time
                        });
    
                    if (me.lastText !== text) {
                        me.setText(text);
                        me.lastText = text;
                    }
    
                    me.timer = Ext.defer(me.updateTime, 1000, me);
                }
            }));
        }
    }

     

    • Like 1
    • Happy 1
  5. 4 hours ago, eduardosuruagy said:

    I'm having trouble cleaning

    We will check.

    Try this workaround for now:

    procedure TMainForm.UniButton2Click(Sender: TObject);
    begin
      UniTagField1.Clear;
      UniTagField1.JSInterface.JSCallDefer('getStore().removeAll', [], 100);
    end;

     

  6. 19 hours ago, gerhardhziegler said:

    do you have any idea how to disable the "NewEvent" Event always shown when the user clicks or range-selects the panel?
    Any ideas appreciated.

    Hello,

    Try this approach:

    MainForm.Script ->

    Ext.override(Ext.calendar.view.Day, {
        allowSelection: false
    });
    
    Ext.override(Ext.calendar.view.Week, {
        allowSelection: false
    });
    Ext.override(Ext.calendar.view.Month, {
        allowSelection: false
    });

     

    • Happy 1
  7. Hello,

    13 minutes ago, SISBLU Software said:

    In my form I have been monitoring the F5 key and calling a function.
    But if I'm inside UNIMEMO and press the F5 key, the system restarts. I need to be OUTSIDE UNIMEMO for the F5 key to call the function

    Can you make a simple testcase to check !?

     

    Also you can use this approach:

    MainForm.Script ->

    Ext.onReady(function() {
        document.addEventListener('keydown', (e) => {
            e = e || window.event;
            if (e.keyCode == 116) {
                e.preventDefault();
            }
        })
    });

     

  8. 17 hours ago, Josué Elias said:

    Is there a plan to have a version of Unigui for Lazarus?

    Quote

    We have considered to create a port for Lazarus, but workload didn't allow us to make it happen. From what I see Lazarus adopts a completely different IDE integration API compared with Delphi. We need to add custom Forms and DataModules to the IDE.

    Are they any resources which explains all the needed step to achieve this? The resource that I have reviewed a few years ago wasn't adequate...

     

×
×
  • Create New...