View Issue Details

IDProjectCategoryView StatusLast Update
0003395Wishes.Plugins_Commonpublic2020-05-12 15:43
ReporterAleXH Assigned Toctapmex  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Fixed in Version3.0 
Summary0003395: FarColorer. Функции определения статуса, включения, выключения.
DescriptionВ 4889 изменилось поведение FarColorer - теперь при использовании RESearch-батчей замен в редакторе, сабж стал красить текст, что привело существенному увеличению времени обработки.

Сделал костыль:
local F = far.Flags
local ColorerMenu = win.Uuid("87C92249-430D-4334-AC33-05E7423286E9")
local ColorerGuid = "D2F36B62-A470-418D-83A3-ED7A3710E5B5"

Event {
  description = "ColorerStatus";
  group = "DialogEvent";
  condition = function(Event,param)
    if Event == F.DE_DLGPROCINIT and param.Msg == F.DN_INITDIALOG then
      local info = param.hDlg:send(F.DM_GETDIALOGINFO)
      return info and info.Id == ColorerMenu
    end
  end;
  action = function(Event,param)
    local hDlg = param.hDlg
    if _G.ColorerOn then
      _G.ColorerPrevStatus = hDlg:send(F.DM_SETCHECK,2,F.BSTATE_CHECKED)
    else
      _G.ColorerPrevStatus = hDlg:send(F.DM_SETCHECK,2,F.BSTATE_UNCHECKED)
    end
  end;
}

local function ColorerConfig()
  --msgbox("Colorer",_G.ColorerOn and "On" or "Off")
  Plugin.Call(ColorerGuid,0)
  Menu.Select("Configure",2)
  Keys("Enter Enter")
end

Macro {
  area = "Common";
  description = "ColorerOff";
  key = "ColorerOff";
  action=function()
    _G.ColorerOn = false
    ColorerConfig()
  end;
}

Macro {
  area = "Common";
  description = "ColorerOn";
  key = "ColorerOn";
  action = function()
    _G.ColorerOn = true
    ColorerConfig()
  end;
}
, который вызывается перед выполнением и после выполнения батча.

Пожелание - сделать определение и сохранение состояния, включение, выключение колорера более удобными.
TagsNo tags attached.

Relationships

parent of 0003509 closed Plugins FarColorer: Plugin.Call("0E92FC81-4888-4297-A85D-31C79E0E0CEE","status") всегда возвращает false 

Activities

shmuel

2017-02-12 13:37

developer   bugnote:0015213

Возможно имеет смысл продублировать на GitHub (или где там репозиторий Colorer живёт).

И не постить целую простыню своего макроса, а ясно расписать, чего же вам нужно, т.к. фраза "сделать ... более удобным" абсолютна неконкретна.

AleXH

2017-02-12 14:18

reporter   bugnote:0015214

Ок, сделать их доступными, например через Plugin.Call().

sonar

2017-02-23 14:23

developer   bugnote:0015218

реализовано

JohnDoe

2017-09-19 07:52

updater   bugnote:0015598

Не работает ни установка ни проверка статуса

JohnDoe

2017-09-26 12:49

updater   bugnote:0015623

Присмотрелся.
В history.ru.txt и в справке встречается неверное значение guid плагина, поэтому и не заработало.

С правильным гуидом всё ок, и можно закрывать, подкорректировав документацию.
Там есть и другие неточности: callplugin и plugin.call вместо правильного названия Plugin.Call

JohnDoe

2017-09-26 12:59

updater   bugnote:0015624

Last edited: 2017-09-26 13:01

Ещё.
В colorere.hlf раздел MacroCallPlugin форматируется неверно, из-за того, что попадаются отступы, сделанные не обычным пробелом, а символом с кодом 0xA0.

2useven10

2017-09-29 15:50

developer   bugnote:0015633

https://github.com/colorer/FarColorer/pull/27/files

Issue History

Date Modified Username Field Change
2017-02-12 13:29 AleXH New Issue
2017-02-12 13:37 shmuel Note Added: 0015213
2017-02-12 14:18 AleXH Note Added: 0015214
2017-02-23 14:23 sonar Note Added: 0015218
2017-09-19 07:52 JohnDoe Note Added: 0015598
2017-09-26 12:49 JohnDoe Note Added: 0015623
2017-09-26 12:59 JohnDoe Note Added: 0015624
2017-09-26 13:01 JohnDoe Note Edited: 0015624
2017-09-29 15:40 2useven10 Relationship added related to 0003509
2017-09-29 15:50 2useven10 Note Added: 0015633
2018-11-15 09:36 JohnDoe Relationship replaced parent of 0003509
2020-05-12 15:43 ctapmex Assigned To => ctapmex
2020-05-12 15:43 ctapmex Status new => assigned
2020-05-12 15:43 ctapmex Status assigned => resolved
2020-05-12 15:43 ctapmex Status resolved => closed
2020-05-12 15:43 ctapmex Resolution open => fixed
2020-05-12 15:43 ctapmex Fixed in Version => 3.0