Форум » GUI » Новая версия Расширенного релиза библиотеки MiniGUI (часть VI ) (продолжение) » Ответить

Новая версия Расширенного релиза библиотеки MiniGUI (часть VI ) (продолжение)

gfilatov: Начало темы находится здесь, а теперь АНОНС * АНОНС * АНОНС * АНОНС * АНОНС Готовится к опубликованию новая сборка №48, которая выйдет в конце недели. Если у Вас есть интересные наработки для включения в новый релиз, то сейчас самое удобное время для их отправки мне Кратко, что нового: - исправление обнаруженных ошибок и неточностей кода; - новый класс HEADERIMAGE для Grid и Browse; - свойство Address в Hyperlink может теперь открывать папку или файл на диске; - добавлен NOTABSTOP класс для Browse; - поддержка пользовательских компонентов (заимствована из оффициального релиза); - расширения и исправления в библиотеках TsBrowse и PropGrid; - обновлены сборки Харбор и HMGS-IDE; - новые и обновленные старые примеры (как обычно ).

Ответов - 300, стр: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 All

gfilatov2002: SergKis пишет: Небольшие добавки Принято

SergKis: gfilatov2002 Предлагаю добавить для dbf use shared и режима :lRowPosAtRec := .T. обновление первой записи на экране, т.к. при ее модификации (в потоке или др. пользователем) буфер RDD остается прежним, не соответствующим записи на диске, т.е. [pre2] CLASS TSBrowse FROM TControl ... DATA lShared AS LOGICAL INIT .F. // dbf file opened shared at .T. ... METHOD SetDbf( cAlias ) CLASS TSBrowse ... IF "ADS" $ ::cDriver ... ELSE ... ::lShared := ( cAlias )->( dbInfo( 36 ) ) // DBI_SHARED 36 /* the file opened shared ? */ ENDIF ... METHOD Refresh( lPaint, lRecount, lClearHash ) CLASS TSBrowse LOCAL nOldRec ... ::lNoPaint := .F. IF ::lIsDbf .and. ::nLen > 0 .and. ::lShared .and. ::lRowPosAtRec .and. HB_ISARRAY( ::aRowPosAtRec ) IF Len( ::aRowPosAtRec ) > 0 nOldRec := ( ::cAlias )->( RecNo() ) ( ::cAlias )->( dbGoto( ::aRowPosAtRec[ 1 ] ) ) IF nOldRec != ::aRowPosAtRec[ 1 ] ( ::cAlias )->( dbGoto( nOldRec ) ) ENDIF ENDIF ENDIF RETURN ::Super:Refresh( lPaint ) [/pre2]

gfilatov2002: SergKis пишет: добавить для dbf use shared и режима :lRowPosAtRec := .T. обновление первой записи на экране Принято с благодарностью Сейчас готовлю 3-е обновление для сборки 23.04


SergKis: gfilatov2002 Немного изменить код выше с :lRowPosAtRec (для удобного использования) [pre2] CLASS TSBrowse FROM TControl ... ACCESS nAtPos INLINE iif( ::lIsDbf, ( ::cAlias )->( RecNo() ), ::nAt ) ACCESS IsRowPosAtRec INLINE ( ::lIsDbf .AND. ::nLen > 0 .AND. ::lRowPosAtRec .AND. HB_ISARRAY( ::aRowPosAtRec ) .AND. Len( ::aRowPosAtRec ) > 0 ) ... METHOD Refresh( lPaint, lRecount, lClearHash ) CLASS TSBrowse ... IF ::IsRowPosAtRec .and. ::lShared nOldRec := ( ::cAlias )->( RecNo() ) ( ::cAlias )->( dbGoto( ::aRowPosAtRec[ 1 ] ) ) IF nOldRec != ::aRowPosAtRec[ 1 ] ( ::cAlias )->( dbGoto( nOldRec ) ) ENDIF ENDIF ... [/pre2]

gfilatov2002: SergKis пишет: Немного изменить код выше Понял, добавил этот код

SergKis: gfilatov2002 Был не прав с :IsRowPosAtRec , работает и с массивом ( ::aRowPosAtRec[ xRow ] := ( nAt := ::nAtPos ) ), надо поправить [pre2] ACCESS IsRowPosAtRec INLINE ( ::lIsDbf .AND. ::nLen > 0 .AND. ::lRowPosAtRec .AND. HB_ISARRAY( ::aRowPosAtRec ) .AND. Len( ::aRowPosAtRec ) > 0 ) и IF ::lIsDbf .and. ::lShared .and. ::IsRowPosAtRec nOldRec := ( ::cAlias )->( RecNo() ) ... [/pre2]

gfilatov2002: SergKis пишет: надо поправить Поправил, конечно. Благодарю за помощь

gfilatov2002: Выложил 3-е обновление сборки 23.04 с учетом последних исправлений и дополнений Скачать Обновил также Unicode архив этой сборки для Сергея... Ну вот и все

SergKis: gfilatov2002 Возникла путаница Было b := This.(cBtn).Action ... This.(cBtn).Action := b Теперь b := This.(cBtn).Action не работает, т.к. (i_this.ch) стало #xtranslate This . <c> . <p:Refresh,SetFocus,DeleteAllItems,Release,Show,Save,Hide,Play,Stop,Close,Pause,Eject,OpenDialog,Resume,Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter,ColumnsAutoFit,ColumnsAutoFitH> [()] => DoMethod ( _HMG_THISFORMNAME, <(c)> , <"p"> ) ... #xtranslate This . <c> . <p:ReadOnly,DisableEdit,Options,Spacing,Speed,Volume,Zoom,Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter> := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <n> ) ... т.е. This.(cBtn).Action := b работает, как и b := GetProperty(cWnd, cBtn, "Action") ... SetProperty(cWnd, cBtn, "Action", b)

gfilatov2002: SergKis пишет: Возникла путаница Поправил, прошу проверить результат ниже: [pre2]/*---------------------------------------------------------------------------- MINIGUI - Harbour Win32 GUI library source code Copyright 2002-2010 Roberto Lopez <harbourminigui@gmail.com> http://harbourminigui.googlepages.com/ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this software; see the file COPYING. If not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA (or visit the web site http://www.gnu.org/). As a special exception, you have permission for additional uses of the text contained in this release of Harbour Minigui. The exception is that, if you link the Harbour Minigui library with other files to produce an executable, this does not by itself cause the resulting executable to be covered by the GNU General Public License. Your use of that executable is in no way restricted on account of linking the Harbour-Minigui library code into it. Parts of this project are based upon: "Harbour GUI framework for Win32" Copyright 2001 Alexander S.Kresin <alex@kresin.ru> Copyright 2001 Antonio Linares <alinares@fivetech.com> www - https://harbour.github.io/ "Harbour Project" Copyright 1999-2023, https://harbour.github.io/ "WHAT32" Copyright 2002 AJ Wos <andrwos@aust1.net> "HWGUI" Copyright 2001-2021 Alexander S.Kresin <alex@kresin.ru> ---------------------------------------------------------------------------*/ // WINDOWS (THIS) #xtranslate This . <p:Title,Parent,NotifyIcon,NotifyTooltip,Cursor,FocusedControl,MinHeight,MinWidth,MaxHeight,MaxWidth,TitleBar,SysMenu,Sizable,Closable,MaxButton,MinButton,Visible,Enabled,Topmost,HelpButton,Object> => GetProperty ( _HMG_THISFORMNAME , <"p"> ) #xtranslate This . <p:Title,NotifyIcon,NotifyTooltip,Cursor,MinHeight,MinWidth,MaxHeight,MaxWidth,TitleBar,SysMenu,Sizable,Closable,MaxButton,MinButton,Visible,Enabled,Topmost,HelpButton> := <arg> => SetProperty ( _HMG_THISFORMNAME , <"p"> , <arg> ) #xtranslate This . <p:OnInit,OnRelease,OnInterActiveClose,OnNotifyClick,OnMouseClick,OnMouseDrag,OnMouseMove,OnMove,OnSize,OnMaximize,OnMinimize,OnPaint,OnRestore,OnDropFiles> := <arg> => SetProperty ( _HMG_THISFORMNAME , <"p"> , <arg> ) #xtranslate This . <p:Activate,Center,Release,Maximize,Minimize,Restore> [()] => DoMethod ( _HMG_THISFORMNAME , <"p"> ) #xtranslate This . <p:Names,Controls> => HMG_GetFormControls ( _HMG_THISFORMNAME , "ALL" ) #xtranslate This . <c> . <p:Names> => HMG_GetFormControls ( _HMG_THISFORMNAME , <(c)> ) #xtranslate This . <c> . <p:ClientWidth> => _GetClientRect ( GetControlHandle ( <(c)> , _HMG_THISFORMNAME ) ) \[3] #xtranslate This . <c> . <p:ClientHeight> => _GetClientRect ( GetControlHandle ( <(c)> , _HMG_THISFORMNAME ) ) \[4] #xtranslate This . <c> . <p:Value,Name,Handle,Type,Index,Address,BackColor,BackgroundColor,FontColor,Picture,Icon,HBitmap,ToolTip,FontName,FontSize,FontBold,FontUnderline,FontItalic,FontStrikeOut,Caption,Row,DisplayValue,Col,Width,Height,Visible,Enabled,Checked,ItemCount,RangeMin,RangeMax,Cargo,Tabstop,ColumnCOUNT> => GetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> ) #xtranslate This . <c> . <p:Value,Name,Address,BackColor,BackgroundColor,FontColor,Picture,Icon,HBitmap,ToolTip,FontName,FontSize,FontBold,FontUnderline,FontItalic,FontStrikeOut,Caption,Row,DisplayValue,Col,Width,Height,Visible,Enabled,Checked,ItemCount,RangeMin,RangeMax,Cargo,Tabstop> := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <n> ) #xtranslate This . <c> . <p:ListWidth,Position,CaretPos,ForeColor,AllowAppend,AllowDelete,AllowEdit,InputItems,DisplayItems,FormatString,Indent,Linecolor,ItemHeight,ValidMessage,AutoFont,RichValue,Alignment,CaseConvert,Transparent,CueBanner,GradientFill,GradientOver,Object,ImageWidth,ImageHeight> => GetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> ) #xtranslate This . <c> . <p:ListWidth,Position,CaretPos,ForeColor,AllowAppend,AllowDelete,AllowEdit,Blink,InputItems,DisplayItems,FormatString,Indent,Linecolor,ItemHeight,ValidMessage,AutoFont,RichValue,Alignment,CaseConvert,Transparent,ColumnWidthLimits,CueBanner,GradientFill,GradientOver,Increment,ImageWidth,ImageHeight> := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <n> ) #xtranslate This . <c> . <p:Caption,Header,Image,Item,Icon,ToolTip,Width,ColumnWidth,Enabled,RichValue,HeaderImage,CheckboxItem,Cargo,Increment,ColumnDISPLAYPOSITION> (<arg>) => GetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <arg> ) #xtranslate This . <c> . <p:Velocity> := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , "Velocity" , <n> ) #xtranslate This . <c> . <p:Caption,Header,Image,Item,Icon,ToolTip,Width,ColumnWidth,Enabled,RichValue,CheckboxItem,Cargo,ColumnDISPLAYPOSITION> (<arg>) := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <arg> , <n> ) #xtranslate This . <c> . <p:Cell> (<arg1> , <arg2>) => GetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <arg1> , <arg2> ) #xtranslate This . <c> . <p:Cell> (<arg1> , <arg2>) := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <arg1> , <arg2> , <n> ) #xtranslate This . <c> . <p:HeaderImage> (<arg1>) := <arg2> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <arg1> , <arg2> ) #xtranslate This . <c> . <p:HeaderImage> (<arg1>) := {<arg2> , <arg3>} => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <arg1> , <arg2> , <arg3> ) #xtranslate This . <c> . <p:Refresh,SetFocus,DeleteAllItems,Release,Show,Save,Hide,Play,Stop,Close,Pause,Eject,OpenDialog,Resume,Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter,ColumnsAutoFit,ColumnsAutoFitH> [()] => DoMethod ( _HMG_THISFORMNAME, <(c)> , <"p"> ) #xtranslate This . <c> . <p:AddItem,DeleteItem,Open,DeletePage,DeleteColumn,Expand,Collapse,Seek,ColumnAutoFit,ColumnAutoFitH> (<a>) => Domethod ( _HMG_THISFORMNAME, <(c)> , <"p"> , <a> ) #xtranslate This . <c> . <p:AddItem,AddPage> (<a1> , <a2> ) => Domethod ( _HMG_THISFORMNAME, <(c)> , <"p"> , <a1> , <a2> ) #xtranslate This . <c> . <p:AddItem,AddPage> (<a1> , <a2> , <a3> ) => Domethod ( _HMG_THISFORMNAME, <(c)> , <"p"> , <a1> , <a2> , <a3> ) #xtranslate This . <c> . <p:AddItem,AddColumn,AddControl,AddPage> (<a1> , <a2> , <a3> , <a4> ) => Domethod ( _HMG_THISFORMNAME, <(c)> , <"p"> , <a1> , <a2> , <a3> , <a4> ) #xtranslate This . <c> . <p:ReadOnly,DisableEdit,Options,Spacing,Length> => GetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> ) #xtranslate This . <c> . <p:ReadOnly,DisableEdit,Options,Spacing,Speed,Volume,Zoom,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter> := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <n> ) #xtranslate This . <x> . <c> . <p:Caption,Enabled,Value> => GetProperty ( _HMG_THISFORMNAME , <(x)> , <(c)> , <"p"> ) #xtranslate This . <x> . <c> . <p:Caption,Enabled,Value> := <n> => SetProperty ( _HMG_THISFORMNAME , <(x)> , <(c)> , <"p"> , <n> ) #xtranslate This . <x> (<k>) . <c> . <p:Value,Name,Address,BackColor,FontColor,Picture,ToolTip,FontName,FontSize,FontBold,FontItalic,FontUnderline,FontStrikeOut,Caption,Row,DisplayValue,Col,Width,Height,Visible,Enabled,Checked,ItemCount,RangeMin,RangeMax,Cargo> => GetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> ) #xtranslate This . <x> (<k>) . <c> . <p:Value,Name,Address,BackColor,FontColor,Picture,ToolTip,FontName,FontSize,FontBold,FontItalic,FontUnderline,FontStrikeOut,Caption,Row,DisplayValue,Col,Width,Height,Visible,Enabled,Checked,ItemCount,RangeMin,RangeMax,Cargo> := <n> => SetProperty ( _HMG_THISFORMNAME , <(x)> , <k> , <(c)> , <"p"> , <n> ) #xtranslate This . <x> (<k>) . <c> . <p:ListWidth,Position,CaretPos,ForeColor,RichValue> => GetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> ) #xtranslate This . <x> (<k>) . <c> . <p:ListWidth,Position,CaretPos,ForeColor,RichValue> := <n> => SetProperty ( _HMG_THISFORMNAME , <(x)> , <k> , <(c)> , <"p"> , <n> ) #xtranslate This . <x> (<k>) . <c> . <p:Caption,Header,Item,Icon,RichValue,CheckboxItem> (<arg>) => GetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <arg> ) #xtranslate This . <x> (<k>) . <c> . <p:Caption,Header,Item,Icon,RichValue,CheckboxItem> (<arg>) := <n> => SetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <arg> , <n> ) #xtranslate This . <x> (<k>) . <c> . <p:Refresh,SetFocus,DeleteAllItems,Release,Show,Save,Hide,Play,Stop,Close,Pause,Eject,OpenDialog,Resume,Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter> [()] => DoMethod ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> ) #xtranslate This . <x> (<k>) . <c> . <p:AddItem,DeleteItem,Open,DeletePage,DeleteColumn,Expand,Collapse,Seek> (<a>) => Domethod ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <a> ) #xtranslate This . <x> (<k>) . <c> . <p:AddItem,AddPage> (<a1> , <a2>) => Domethod ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <a1> , <a2> ) #xtranslate This . <x> (<k>) . <c> . <p:AddItem,AddPage> (<a1> , <a2> , <a3> ) => Domethod ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <a1> , <a2> , <a3> ) #xtranslate This . <x> (<k>) . <c> . <p:AddItem,AddColumn,AddControl,AddPage> (<a1> , <a2> , <a3> , <a4> ) => Domethod ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <a1> , <a2> , <a3> , <a4> ) #xtranslate This . <x> (<k>) . <c> . <p:Length,Options,Spacing> => GetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> ) #xtranslate This . <x> (<k>) . <c> . <p:ReadOnly,DisableEdit,Options,Spacing,Speed,Volume,Zoom> := <n> => SetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <n> ) #xtranslate This . <x> (<k>) . <c> . <p:Cell> (<arg1> , <arg2>) => GetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <arg1> , <arg2> ) #xtranslate This . <x> (<k>) . <c> . <p:Cell> (<arg1> , <arg2>) := <n> => SetProperty ( _HMG_THISFORMNAME, <(x)> , <k> , <(c)> , <"p"> , <arg1> , <arg2> , <n> ) #xtranslate This . SplitBox . <c> . <p:Value,Name,Address,BackColor,FontColor,Picture,ToolTip,FontName,FontSize,FontBold,FontItalic,FontUnderline,FontStrikeOut,Caption,Row,DisplayValue,Col,Width,Height,Visible,Enabled,Checked,ItemCount,RangeMin,RangeMax,Position,CaretPos,ForeColor,AllowEdit,Object,InputItems,DisplayItems,Cargo> => GetProperty ( _HMG_THISFORMNAME, "SplitBox" , <(c)> , <"p"> ) #xtranslate This . SplitBox . <c> . <p:Value,Name,Address,BackColor,FontColor,Picture,ToolTip,FontName,FontSize,FontBold,FontItalic,FontUnderline,FontStrikeOut,Caption,Row,DisplayValue,Col,Width,Height,Visible,Enabled,Checked,ItemCount,RangeMin,RangeMax,Position,CaretPos,ForeColor,AllowEdit,Blink,InputItems,DisplayItems,Cargo> := <n> => SetProperty ( _HMG_THISFORMNAME, "SplitBox" , <(c)> , <"p"> , <n> ) #xtranslate This . SplitBox . <c> . <p:AllowAppend,AllowDelete,DisableEdit,ReadOnly> => GetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> ) #xtranslate This . SplitBox . <c> . <p:AllowAppend,AllowDelete,DisableEdit,ReadOnly> := <n> => SetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <n> ) #xtranslate This . SplitBox . <c> . <p:Caption,Header,Item,Icon,HeaderImages,CheckboxItem> (<arg>) => GetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <arg> ) #xtranslate This . SplitBox . <c> . <p:Caption,Header,Item,Icon,HeaderImages,CheckboxItem> (<arg>) := <n> => SetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <arg> , <n> ) #xtranslate This . SplitBox . <c> . <p:Cell> (<arg1> , <arg2>) => GetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <arg1> , <arg2> ) #xtranslate This . SplitBox . <c> . <p:Cell> (<arg1> , <arg2>) := <n> => SetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <arg1> , <arg2> , <n> ) #xtranslate This . SplitBox . <c> . <p:Refresh,SetFocus,DeleteAllItems,Release,Show,Save,Hide,Play,Stop,Close,Pause,Eject,OpenDialog,Resume,Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter> [()] => DoMethod ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> ) #xtranslate This . SplitBox . <c> . <p:AddItem,DeleteItem,Open,DeletePage,DeleteColumn,Expand,Collapse,Seek> (<a>) => Domethod ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <a> ) #xtranslate This . SplitBox . <c> . <p:AddItem,AddPage> (<a1> , <a2>) => Domethod ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <a1> , <a2> ) #xtranslate This . SplitBox . <c> . <p:AddItem,AddPage> (<a1> , <a2> , <a3> ) => Domethod ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <a1> , <a2> , <a3> ) #xtranslate This . SplitBox . <c> . <p:AddItem,AddColumn,AddControl,AddPage> (<a1> , <a2> , <a3> , <a4> ) => Domethod ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <a1> , <a2> , <a3> , <a4> ) #xtranslate This . SplitBox . <c> . <p:Name,Length> => GetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> ) #xtranslate This . SplitBox . <c> . <p:ReadOnly,DisableEdit,Speed,Volume,Zoom> := <n> => SetProperty ( _HMG_THISFORMNAME, "SplitBox", <(c)> , <"p"> , <n> ) #xtranslate This . SplitBox . <x> . <c> . <p:Caption,Enabled,Value> => GetProperty ( _HMG_THISFORMNAME , "SplitBox" , <(x)> , <(c)> , <"p"> ) #xtranslate This . SplitBox . <x> . <c> . <p:Caption,Enabled,Value> := <n> => SetProperty ( _HMG_THISFORMNAME , "SplitBox", <(x)> , <(c)> , <"p"> , <n> ) // WINDOWS (THISWINDOW) #xtranslate ThisWindow . <p:Title,Parent,NotifyIcon,NotifyTooltip,Cursor,FocusedControl,BackColor,Name,Handle,Type,Index,Row,Col,Width,Height,MinHeight,MinWidth,MaxHeight,MaxWidth,TitleBar,SysMenu,Sizable,Closable,MaxButton,MinButton,Visible,Enabled,Topmost,HelpButton,Cargo,Object> => GetProperty ( _HMG_THISFORMNAME , <"p"> ) #xtranslate ThisWindow . <p:Title,NotifyIcon,NotifyTooltip,Cursor,BackColor,Row,Col,Width,Height,MinHeight,MinWidth,MaxHeight,MaxWidth,TitleBar,SysMenu,Sizable,Closable,MaxButton,MinButton,Visible,Enabled,Topmost,HelpButton,Cargo> := <arg> => SetProperty ( _HMG_THISFORMNAME , <"p"> , <arg> ) #xtranslate ThisWindow . <p:OnInit,OnRelease,OnInterActiveClose,OnGotFocus,OnLostFocus,OnNotifyClick,OnMouseClick,OnMouseDrag,OnMouseMove,OnMove,OnSize,OnMaximize,OnMinimize,OnPaint,OnRestore,OnDropFiles> := <arg> => SetProperty ( _HMG_THISFORMNAME , <"p"> , <arg> ) #xtranslate ThisWindow . <p:AlphaBlendTransparent,BackColorTransparent> := <arg> => SetProperty ( _HMG_THISFORMNAME , <"p"> , <arg> ) #xtranslate ThisWindow . <p:Activate,Center,EnableUpdate,DisableUpdate,Redraw,Release,Maximize,Minimize,Restore,Show,Hide,SetFocus> [ () ] => DoMethod ( _HMG_THISFORMNAME , <"p"> ) #xtranslate ThisWindow . <p:Names,Controls> => HMG_GetFormControls ( _HMG_THISFORMNAME , "ALL" ) #xtranslate ThisWindow . <p:ClientWidth> => _GetClientRect ( GetFormHandle ( _HMG_THISFORMNAME ) ) \[3] #xtranslate ThisWindow . <p:ClientHeight> => _GetClientRect ( GetFormHandle ( _HMG_THISFORMNAME ) ) \[4] // CONTROLS // RichEditBox ( by Dr. Claudio Soto, January 2014 ) #xtranslate ThisRichEditBox . <p: GetClickLinkRange,GetClickLinkText> => GetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> ) * Property without arguments #xtranslate This . <p:FontColor,ForeColor,Value,ReadOnly,DisableEdit,Options,Spacing,Address,Picture,Icon,HBitmap,Tooltip,FontName,FontSize,FontBold,FontItalic,FontUnderline,FontStrikeout,Caption,Displayvalue,Visible,Enabled,Checked,ItemCount,RangeMin,RangeMax,Length,Position,CaretPos,Alignment,CaseConvert,Transparent,CueBanner,GradientFill,GradientOver,Increment,ImageWidth,ImageHeight,ColumnCOUNT,FormatString> => GetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> ) #xtranslate This . <p:FontColor,ForeColor,Value,ReadOnly,DisableEdit,Options,Spacing,Address,Picture,Icon,HBitmap,Tooltip,FontName,FontSize,FontBold,FontItalic,FontUnderline,FontStrikeout,Caption,DisplayValue,Visible,Enabled,Checked,RangeMin,RangeMax,Repeat,Speed,Volume,Zoom,Position,CaretPos,Action,Blink,Alignment,CaseConvert,Transparent,ColumnWidthLimits,CueBanner,GradientFill,GradientOver,Increment,ImageWidth,ImageHeight,FormatString> := <arg> => SetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <arg> ) * Property with 1 argument #xtranslate This . <p:Item,Caption,Header,Icon,Width,ColumnWidth,ColumnDISPLAYPOSITION,Enabled> (<n>) => GetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <n> ) #xtranslate This . <p:Item,Caption,Header,Icon,Width,ColumnWidth,ColumnDISPLAYPOSITION,Enabled> (<n>) := <arg> => SetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <n> , <arg> ) #xtranslate This . <p:ColumnCONTROL,ColumnDYNAMICBACKCOLOR,ColumnDYNAMICFORECOLOR,ColumnJUSTIFY,ColumnVALID,ColumnWHEN,ColumnVALIDMESSAGE,ColumnONHEADCLICK,HeaderDYNAMICFONT,HeaderDYNAMICBACKCOLOR,HeaderDYNAMICFORECOLOR> (<n>) => GetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <n> ) #xtranslate This . <p:ColumnCONTROL,ColumnDYNAMICBACKCOLOR,ColumnDYNAMICFORECOLOR,ColumnJUSTIFY,ColumnVALID,ColumnWHEN,ColumnVALIDMESSAGE,ColumnONHEADCLICK,HeaderDYNAMICFONT,HeaderDYNAMICBACKCOLOR,HeaderDYNAMICFORECOLOR> (<n>) := <arg> => SetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <n> , <arg> ) * Property with 2 arguments #xtranslate This . <p:Cell> ( <n1> , <n2> ) => GetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <n1> , <n2> ) #xtranslate This . <p:Cell> ( <n1> , <n2> ) := <arg> => SetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <n1> , <n2> , <arg> ) * Method without arguments #xtranslate This . <p:Redraw,Refresh,DeleteAllItems,Release,Play,Stop,Close,PlayReverse,Pause,Eject,OpenDialog,Resume,Save,GetArray,EnableUpdate,DisableUpdate,Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter,ColumnAutoFit,ColumnAutoFitH> [ () ] => DoMethod ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> ) * Method with 1 argument #xtranslate This . <p:AddItem,DeleteItem,Open,Seek,SetArray,DeletePage,DeleteColumn,Expand,Collapse> (<arg>) => DoMethod ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <arg> ) * Method with 2 arguments #xtranslate This . <p:AddItem,AddPage> ( <arg1> , <arg2> ) => DoMethod ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <arg1> , <arg2> ) * Method with 3 arguments #xtranslate This . <p:AddItem,AddPage> ( <arg1>,<arg2>,<arg3> ) => DoMethod ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <arg1> , <arg2> , <arg3> ) * Method with 4 arguments #xtranslate This . <p:AddItem,AddControl,AddColumn,AddPage> ( <arg1> , <arg2> , <arg3> , <arg4> ) => DoMethod ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <arg1> , <arg2> , <arg3> , <arg4> ) // COMMON ( REQUIRES TYPE CHECK ) #xtranslate This . <p:Name,Handle,Type,Index,Row,Col,Width,Height,BackColor,Cargo,Object> => iif ( _HMG_THISType == 'C' , GetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> ) , GetProperty ( _HMG_THISFORMNAME , <"p"> ) ) #xtranslate This . <p:Row,Col,Width,Height,BackColor,Cargo> := <arg> => iif ( _HMG_THISType == 'C' , SetProperty ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> , <arg> ) , SetProperty ( _HMG_THISFORMNAME , <"p"> , <arg> ) ) #xtranslate This . <p:Show,Hide,SetFocus> [ () ] => iif ( _HMG_THISType == 'C' , DoMethod ( _HMG_THISFORMNAME , _HMG_THISCONTROLNAME , <"p"> ) , DoMethod ( _HMG_THISFORMNAME , <"p"> ) ) #xtranslate This . <p:ClientWidth> => _GetClientRect ( iif ( _HMG_THISType == 'C' , GetControlHandle ( _HMG_THISCONTROLNAME , _HMG_THISFORMNAME ) , GetFormHandle ( _HMG_THISFORMNAME ) ) ) \[3] #xtranslate This . <p:ClientHeight> => _GetClientRect ( iif ( _HMG_THISType == 'C' , GetControlHandle ( _HMG_THISCONTROLNAME , _HMG_THISFORMNAME ) , GetFormHandle ( _HMG_THISFORMNAME ) ) ) \[4] // EVENT PROCEDURES #xtranslate This . QueryRowIndex => _HMG_THISQueryRowIndex #xtranslate This . QueryColIndex => _HMG_THISQueryColIndex #xtranslate This . QueryData => _HMG_THISQueryData #xtranslate This . CellRowIndex => _HMG_THISItemRowIndex #xtranslate This . CellColIndex => _HMG_THISItemColIndex #xtranslate This . CellRow => _HMG_THISItemCellRow #xtranslate This . CellCol => _HMG_THISItemCellCol #xtranslate This . CellWidth => _HMG_THISItemCellWidth #xtranslate This . CellHeight => _HMG_THISItemCellHeight #xtranslate This . CellValue => _HMG_THISItemCellValue #xtranslate This . CellValue := <arg> => _SetGridCellEditValue ( <arg> ) // INPLACE EDIT GRID EVENT #xtranslate This . InplaceEditControlHandle => _HMG_GridInplaceEdit_ControlHandle #xtranslate This . InplaceEditControlIndex => _HMG_GridInplaceEdit_GridIndex #xtranslate This . InplaceEditGridName => iif( _HMG_GridInplaceEdit_GridIndex > 0, _HMG_aControlNames \[ _HMG_GridInplaceEdit_GridIndex ], "" ) #xtranslate This . InplaceEditParentName => iif( _HMG_GridInplaceEdit_GridIndex > 0, GetParentFormName( _HMG_GridInplaceEdit_GridIndex ), "" ) #xtranslate This . IsInplaceEditEventInit => ( _HMG_GridInplaceEdit_StageEvent == 1 ) #xtranslate This . IsInplaceEditEventRun => ( _HMG_GridInplaceEdit_StageEvent == 2 ) #xtranslate This . IsInplaceEditEventFinish => ( _HMG_GridInplaceEdit_StageEvent == 3 ) [/pre2]

SergKis: gfilatov2002 пишет прошу проверить Проверил, с new i_this.ch ошибка компиляции на строке This.(cBtn).Action := b Пример тут https://TransFiles.ru/r516c строки помечены (начало) //!!! new i_this.ch PS. такое же как i_this.ch содержимое i_window.ch

gfilatov2002: SergKis пишет: с new i_this.ch ошибка компиляции на строке Да, у меня такая же ошибка в этой строке. Поэтому вернул старый i_this.ch обратно. SergKis пишет: такое же как i_this.ch содержимое i_window.ch Именно так Я снова проверил эти определения для свойства Action, и они все используют вызов функции DoMethod() Поэтому для вашего случая надо использовать вызов b := GetProperty(cWnd, cBtn, "Action") как и сделано в вашем примере.

SergKis: gfilatov2002 тогда немного не логично в названиях, т.е. далее идут списком как события OnClick,On..., и к ним Domethod () подходит, а Action выпадает (для события OnAction название подходит). #xtranslate This . <c> . <p:...,Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,... Может тогда сделать дополнительно OnAction,Click,GotFocus,LostFocus,Change,DblClick => Get\SetProperty(...) Получается установить можем This.(cBtn).Action := b а прочитать, в таком же синтаксисе, нет b := This.(cBtn).Action

gfilatov2002: SergKis пишет: Получается установить можем This.(cBtn).Action := b а прочитать, в таком же синтаксисе, нет b := This.(cBtn).Action Согласен. Но для Минигуи основным синтаксисом является Get\SetProperty(...) Кстати, в официальной версии HMG вообще не существует определений свойства Action для синтаксиса This

SergKis: gfilatov2002 пишет Кстати, в официальной версии HMG вообще не существует определений свойства Action для синтаксиса This Там много чего удобного нет, потому и не используем ее. А товарищ пошел дальше и обвязал в MiniGui все _Define... объектами и пишет как в VO (привычка), а oHMG - слабоват был на 2011 г.

SergKis: gfilatov2002 Добавил в i_this.ch [pre2] #xtranslate This . <c> . Event . <p:Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter> => GetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> ) #xtranslate This . <c> . Event . <p:Action,OnClick,OnGotFocus,OnLostFocus,OnChange,OnDblClick,OnEnter> := <n> => SetProperty ( _HMG_THISFORMNAME, <(c)> , <"p"> , <n> ) в примере b := This.(cBtn).Event.Action ... This.(cBtn).Action := b или This.(cBtn).Event.Action := b [/pre2] работает

gfilatov2002: SergKis пишет: Добавил в i_this.ch Продублировал у себя эти изменения SergKis пишет: работает Благодарю за помощь

gfilatov2002: По ходу добавил пример отображения строки с разным цветом букв (давно был запрос об этой возможности ). Разноцветная строка рисуется по окну в событии ON PAINT: Если есть интерес в таком примере - напишите...

SergKis: gfilatov2002 пишет Если есть интерес в таком примере - напишите... Если бы окно было Transparent к нижним окнам, было бы super. Андрей бы точно с использовал и много раз.

SergKis: gfilatov2002 Почему убрано ? [pre2] METHOD LDblClick( nRowPix, nColPix, nKeyFlags ) CLASS TSBrowse ... #if 0 ELSEIF nClickRow == -1 .AND. ! Empty( ::lDrawFooters ) // Added 19.05.2020 IF ::bLDblClick != NIL Eval( ::bLDblClick, uPar1, uPar2, nKeyFlags, Self ) ENDIF #endif ELSEIF nClickRow == -2 .AND. ::lDrawSpecHd // SergKis 11.11.21 ... [/pre2] тогда :bLDblClick не работает для Footer



полная версия страницы