Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

Post your working scripts, libraries and tools for AHK v1.1 and older
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

18 Feb 2017, 05:50

Lintalist v1.9.2 published https://github.com/lintalist/lintalist/releases/

Icons also visisible in the context menu and additional icons to indicate the scripts, shorthand, shortcut states in the button bar (a small prohibited circle is overlayed on the icon)
User avatar
boiler
Posts: 16767
Joined: 21 Dec 2014, 02:44

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

26 Feb 2017, 20:25

I've encountered an issue when trying to use Lintalist while also using another AHK script with hotstrings. Hotkeys don't cause any problems, but the first time I use a hotstring from my other script, then my Lintalist activation key doesn't work (my activation key is not related to my hotstring at all), and I can't open Lintalist from the tray icon either after that. I have to close Lintalist and run it again, but it's disabled again the next time I use a hotstring.

I know I can perform the equivalent of hotstrings using Lintalist, but it's not quite as responsive as a direct AHK hotstring, so I'd rather use that.
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

27 Feb 2017, 12:24

Oh noes a bug - thank you for reporting it!

I don't experience this issue myself and have several scripts with various hotstrings/hotkeys running at the same time so I suspect there is some sort of exception.
(both 32 & 64 bit)

General info: If your "hotstrings" are plain and simple you can #include them in AutoHotkey as I'm doing, so all my typo corrections abuot -> about are included in a script autocorrect.ahk which resides in my Lintalist folder. This is described here as well https://github.com/lintalist/lintalist/ ... -263401545 (or look at the last line of your lintalist.ahk)

1: Has this always been the case or just recently?

2: Which hotkey have you setup to open the Lintalist search gui?

3: Does it happen when you disable shorthand and/or shorcuts in Lintalist - you can now click the buttons in the search gui :-)

4: Can you track it to a specific hotstring / bundle combination or does it always happen?
User avatar
boiler
Posts: 16767
Joined: 21 Dec 2014, 02:44

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

28 Feb 2017, 00:10

Here's what I found after a lot of experimenting. In response to your questions:

1: I have not tried to use hotstrings from a different AHK script at the same time as Lintalist until just very recently (last few days).

2: I was using Insert as the search hotkey, but it exhibits the same behavior using CapsLock.

3: It seems to be indifferent to these settings.

4: It appears that it happens if the replacement text of the hotstring contains an extended/special character such as € or ä but only when it follows a capital letter (e.g., "Märt" causes the problem, but "märt" doesn't). Very strange. To be clear, these are hotstrings set by another script, not in Lintalist. When one of those hotstrings is activated, it knocks out the Lintalist search hotkey (CapsLock becomes normal CapsLock again).
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

28 Feb 2017, 12:08

Thank you boiler, I can confirm this and it is easy to replicate using two short test scripts, I've posted in Ask for Help to see what is going on
https://autohotkey.com/boards/viewtopic.php?f=5&t=28649

( perhaps I'm missing some extremely obvious in which case I will hang my head in shame :oops: )
User avatar
boiler
Posts: 16767
Joined: 21 Dec 2014, 02:44

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

28 Feb 2017, 13:42

I didn't think to check to see if it was a general AHK issue. Sorry to wrongly attribute it to your fine program. :)
comvox
Posts: 19
Joined: 29 Sep 2013, 22:48

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

15 Mar 2017, 11:56

Wow! Lintalist is not just powerful, but there's a lot of attention to usability and it's beautiful as well. Thank you so very much for posting it.

Some suggestions for consideration:

* it would be useful if one could search on the list of entries which is the result of a previous search. At present, search always acts on all entries, not simply the ones being displayed.

* It would be nice if one could use an "AND" operator in a search. However, if one could search on the results of a search, one wouldn't need an AND operator. One could first search for items with one term, and then search the results for the second term. (With regular expressions, one can already search for items that have several terms in a definite order, but it's difficult to search for items that have several terms appearing in any order.) Added later: Oops. I see Lintalist already has this with Fuzzy Search! Excellent!


* It would be nice if an item could call up a search (setting both the text of the query and the search mode). Maybe this can be done with a proper script attached to an item, but I wasn't successful in figuring out the script. Having items that could call up searches would allow one to have a certain menu of searches, and it would do so without complicating how Lintalist works for anyone who doesn't care for this capability.

* Maybe it's just me, but I had trouble understanding "Lock". Perhaps it could be explained in "help". Or maybe it's already there, and I missed it.
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

16 Mar 2017, 14:24

comvox wrote:Thank you so very much for posting it.
You're welcome, glad you find it useful :)
comvox wrote:* it would be useful if one could search on the list of entries which is the result of a previous search. At present, search always acts on all entries, not simply the ones being displayed.
Do you mean to speed up the results? So you have 25 results and type a new character/word it would search all entries again to filter the results, but instead you want it to just search the 25 results(1)? Or do you want to save the 25 results somehow and then be able to save those results and then be able to search those later?
(1) there is an issue here that Lintalist stops searching after a defined number of results, there is no point displaying 500 results from a bundle as the scrolling it to tedious so it just displays 30 (and when you continue typing it searches all entries again). So the "25" results may not be all available results from your search.
comvox wrote:* It would be nice if an item could call up a search (setting both the text of the query and the search mode). .... Having items that could call up searches would allow one to have a certain menu of searches, and it would do so without complicating how Lintalist works for anyone who doesn't care for this capability.
Well there is the QuickSearchHotkey "It will cut (ctrl-x) the word to the left, open Lintalist and starts a search." Default setup is winkey-z (#z) - it can't set the search mode, but once the search Gui is active you can use the shortcuts to switch search modes if required. Not sure how useful a "search history" or "save preferred search" would be, most likely the mouse and/or keyboard actions to call up a previous search would take as much time as simply start typing some keywords? But perhaps you have some practical examples in mind?
comvox wrote:* Maybe it's just me, but I had trouble understanding "Lock". Perhaps it could be explained in "help". Or maybe it's already there, and I missed it.
Its there :) Say you have 5 context sensitive bundles, and one bundle is only active in text editor, but you need those snippets in Excel for a few minutes.
You can do that by bringing up the search Gui, select the Bundle you need from the Bundle menu and you can now search that "text editor bundle" each time you bring up the Gui. It would be tedious to have to select the bundle manually each time, so when you select a bundle it LOCKS the bundle so it is always used. That way it saves you the trouble of selecting it manually each time. When you're done you can simply UNLOCK the bundle and it will work as before and next time you bring up the Search Gui the "text editor" bundle is no longer active in Excel. When you select "load all bundles" it is also locked, again for the same reason: to avoid having to select it manually each time. Hope that explains it. (Just try it and see what happens)
comvox
Posts: 19
Joined: 29 Sep 2013, 22:48

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

21 Mar 2017, 10:54

Thank you for your detailed and useful reply!

Lock: Your explanation of "Lock" was helpful. It hadn't occurred to me that its purpose was it paralyzed context-sensitive changes of bundle as I wasn't using context-sensitive bundles. I had originally studied the help file to get an idea about what Lintalist would do. I had seen the references in help to Lock, but when I experimented Lock didn't seem to operate differently from simply selecting the bundle without Lock. But this was because I wasn't using context-sensitive bundles.

QuickSearchHotkey: That's quite useful. And I agree with you that a search history or even droplist of searches might not be worth it. They also wouldn't be flexible in the way I was thinking about, which requires that the script attached to an item be able to call a search. This would allow one to have menus of searches, while not affecting the GUI or bothering users who didn't want such a thing. However, it is not clear anyone else would be interested in what I was thinking about, and for myself, I can still put search words in an item, and just take a few more keystrokes to activate the search, instead of having an item activate search automatically. So it's not a big deal. But, I thought, no harm in asking, just in case a script really could directly call a search.

Searching a search: I didn't suggest this for speed. It would allow one to have fancy searches. For example, if Lintalist had this capability, one could do a regex search on the results of a regex search (while fuzzy search combines simple searches). However, there already is fuzzy search, which is powerful, so it's not clear how much anyone else would really use search on the results of a search. (I was very fond of an old Palm program called Memoleaf, and in part was trying to see whether one of the things that I could do in Lintalist was to work with stored notes in the same way that I had in Memoleaf.)

On a totally different issue. At one point I had the problem that, out of nowhere, Lintalist stopped working. When I called it, I would get an error message from AHK that said that the x option on line 284 was invalid. I panicked, as i wanted Lintalist back! Well, the error message wasn't of much use, and indeed it was rather odd, as the x isn't invalid. I thought maybe the problem was a result of some change I had made on my system. But nothing seemed to make a difference. I worried whether I (or AVG) had somehow corrupted the lintalist.exe or lintalist.ahk files, so I copied them over. That didn't work. I also tried reinstalling Lintalist, but without overwriting the bundles folder. That didn't work. Finally I just reinstalled Lintalist completely, so even the bundles folder was back to the original. Then Lintalist worked again, and it continued to work when I copied my bundles, which I had backed up, back to the bundles folder.
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

21 Mar 2017, 12:31

Error: The "x" error on line 284 indicates a variable is empty which shouldn't be empty. I have never experienced this myself so if you happen to notice it again and what it is you may have done just prior to it do let me know. I can easily add a check to ensure "barx" and "Yctrl" aren't empty - I'll make a note for the next update.

As a rule unpacking / updating lintalist shouldn't overwrite any existing bundles, not even the default.txt one as that is only created when it doesn't exist. Closing Lintalist and starting it again should "set" the "barx" variable automatically as it is calculated at start up.

As you indicated you can indeed easily create a script to bring up Lintalist and start a search, basic example using a menu:

Code: Select all

; Example of a simple menu to call Lintalist (make sure it is running first) - a check could be added of course.
#SingleInstance, force
SetTitleMatchMode, 2
SetKeyDelay 70
DetectHiddenWindows, On

#InputLevel 1 ; This should ensure the SENDs will activate Lintalist
SendLevel 1

; Create the popup menu by adding some items to it.
Menu, MyMenu, Add, SearchText 1, MenuHandler
Menu, MyMenu, Add, SearchText 2, MenuHandler
return  ; End of script's auto-execute section.

#z::Menu, MyMenu, Show  ; i.e. press the Win-Z hotkey to show the menu.

MenuHandler:
Send {Capslock} ; change this if you have changed the default hotkey for Lintalist
WinWaitActive, Lintalist ahk_class AutoHotkeyGUI
ControlSetText, Edit1, %A_ThisMenuItem%, Lintalist ahk_class AutoHotkeyGUI
Sleep 10
ControlSend, Edit1, {end}, Lintalist ahk_class AutoHotkeyGUI ; set caret at end, results should be visible...
Return
Edit: it would be possible to add something like OnMessage() - last example https://autohotkey.com/docs/commands/OnMessage.htm - to Lintalist so you could "control" Lintalist from another script, but as you can see from the example above it is relatively easy to do using a simple Send. There are also a few command line options which may be useful (settings, bundle, active) http://lintalist.github.io/#cmdline
comvox
Posts: 19
Joined: 29 Sep 2013, 22:48

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

22 Mar 2017, 22:13

Script: Thank you very much for the for the script! It can be run from within a Lintalist item, or outside Lintalist (so long as Lintalist is running). It is easily modified to do various things which I would like to do with a script, so it provides a lot of flexibility. For example, I can drop
#z::Menu, MyMenu, Show ; i.e. press the Win-Z hotkey to show the menu.
and simply put
Menu, MyMenu, Show
at the end of the auto-exec section, for using the script when it is attached to an item.

Error: Today I called up Lintalist and it worked. After running it awhile, I decided to see if I could reproduce the error, so I could report what caused it. I think that what might have happened originally is that, when I was checking Lintalist to make sure it hadn't been attacked by AVG, I accidentally called Lintalist while it was still running. (I have since ditched AVG.) So today, while Lintalist was still running, I called Lintalist.exe again (i.e. I don't mean calling up the search window via Capslock, but running Lintalist.exe again). Then I got the error. The bad option on line 284. It seems as if it tries to have two copies running simultaneously, and the error arises. And once the error arises, then even if I exit from Lintalist, and try to be completely exited, I get the error if I run Lintalist.exe. I can reboot Windows 7, and still, when I run Lintalist I get the error.

However, if I deleted settings.ini in the Lintalist folder, then I could call Lintalist, and it ran properly, and recreated settings.ini. So I thought maybe settings.ini had been corrupted. But when I tried to check that, I couldn't verify whether it had been or not. It seemed like, in my different error tests, the settings.ini file sometimes acted strangely, so I couldn't even verify what was in it, but at other times was normal, and unchanged.

To make things more mystifying, I decided to do a final check to make sure that my results were reproducible. But now if I run Lintalist while it is still running, everything is OK. There is no error. I don't get multiple icons for Lintalist. It doesn't try to run two copies. Instead it just works fine. As it should. So for now, I can't get the error no matter what I do. Of course, normally I don't want to get the error...and hope it never reappears. But somehow I feel confident with the idea that, if something should happen, probably all I have to do is delete settings.ini.
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

24 Mar 2017, 13:56

@comvox: Thanks for the additional info, I can't get it to run twice myself so I suspect it is a "rare" issue that won't happen very often. I suspect the "width" variable isn't saved properly when there are two copies of lintalist running so when it tries to read the value and then calculate the variable "barx" it can't do so and throws the error message.

Just so you know: lintalist.exe is a renamed autohotkey.exe (32bit unicode version) - so you could actually delete lintalist.exe. You're correct that by deleting settings.ini it will simply start with a new "fresh" set up.
The Rancid

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

13 Apr 2017, 03:46

Hi,
I experienced the same error message at line 284 when I inadvertantly switched from wide to narrow mode and then rebooted the PC.
I temporarily resolved putting the following just before line 284 in lintalist.ahk:

If (barx="")
barx:=0

I also found that it wasn't needed anymore if I switched back to wide mode.
I don't know if this may be the culprit, but I thought I could mention it.
Best regards
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

14 Apr 2017, 03:53

The Rancid wrote:when I inadvertently switched from wide to narrow mode and then rebooted
Thanks for the report, very useful. Looks like I can replicate it and thus fix it, will be included in the next update.
guesthere

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

15 Jun 2017, 15:11

Great progarm! Thanks for sharing!

Can I keep Lintalist window open after pasting?
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

15 Jun 2017, 16:24

guesthere wrote:Can I keep Lintalist window open after pasting?
No I'm afraid not at the moment. You can assign hotkeys and "hotstrings" to snippets so you don't have to open the search each time for often used snippets.
It has been asked before and I'll think about it. With "+AlwaysOnTop +E0x08000000 ; +E0x08000000 = WS_EX_NOACTIVATE" it can probably be made to work.
Or more fancy, make it dockable - https://autohotkey.com/boards/viewtopic.php?f=6&t=30912

I've opened an issue here to keep track of it https://github.com/lintalist/lintalist/issues/74
mrmed
Posts: 3
Joined: 15 Jun 2017, 02:53

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

16 Jun 2017, 12:55

Thanks for the quick response. I don't know Autohotkey yet but I tried to hack the script by removing calls to Gui Destroy, which didn't work. I tried calling Gosub GuiStart after pasting to reopen the Lintalist window but it's opening centered and on a different monitor. My center configuration is set to "2 = Do not center but remember position set by user". Why isn't the window re-opening in the same position?
list
Posts: 221
Joined: 26 Mar 2014, 14:03
Contact:

Re: Lintalist 1.9 Searchable interactive lists to copy & paste text with plugins

16 Jun 2017, 13:20

I don't have a multiple monitor setup at the moment so can't check but did you restart/reload Lintalist after you changed the setting to 2? Otherwise it sound like it isn't storing the position which is done here upon closing the window https://github.com/lintalist/lintalist/ ... .ahk#L1601

I'm afraid it is a little more complicated at it looks at first glance. When you open the search window it stores some information about the current application and control you are in (GetActiveWindowStats() - https://github.com/lintalist/lintalist/ ... t.ahk#L270). After selecting the snippet Lintalist tries to paste it in the Window/Control that was active when you opened it. So you need to skip that as well. It probably requires some serious "hacking" to "bypass" the regular flow of the program.

Edit: I think I see what you mean with opening centered again, if I close the Gui with the red X at the top right it doesn't see to fire the 1GuiClose label so it doesn't store the current position. As I never use(d) that I didn't notice it earlier - if you press ESC it will fire the label and store the position. It should probably also write the XY to the settings to if you start the program again it remembers the position between sessions.

Edit2: changing 1guiclose to guiclose does the trick, will also ensure XY is saved on exit and read at startup in the next update.

Return to “Scripts and Functions (v1)”

Who is online

Users browsing this forum: No registered users and 113 guests