Auto-Completion Is this Legal?
-
Thanks for the change.
Thanks for the clarification of the Preferences inclusion. I suspected as much, but thought I better verify that.
I agree with most of your point about the User defining, the problem is that if it was so easy for them to make one, they wouldn’t have been asking if there was one, and would have made it. After what you and I have been going through, I’d like to bullet-proof it so I’m not being asked “How do I undo what I did?” questions. :-)
Thanks again, and Merry Christmas and Happy New Year if I don’t get back in here as I’m trying to madly finish the grunt work on the functions to get it done for the Holidays. :-)
Lee
-
@peterjones said in Auto-Completion Is this Legal?:
I will add it to my TODO list to clarify the description in the usermanual to make it more clear what “word” vs “function” is.
The updated User Manual has been released, and now https://npp-user-manual.org/docs/preferences/#auto-completion does a better job of clarifying “word” vs “function” in those preferences.
-
-
@lycan-thrope
Peter, et al,According to the documentation:
For any given function, all text, plus 2 bytes per parameter, plus 24 bytes if 2 overloads or more, can’t spill over 2,043 bytes. Remember that a byte is a byte, so formatting whitespace competes with actual text.
I should be limited to that size for an entire function with overloads. However, prior to trimming it for size per the recommentations, I was functional with a size of well over 2200 characters. This happened because I changed the hard code<>
characters to the escaped versions, thereby increasing each angle brackets character count from 1 to at least 4 characters per angle bracket, unless the escaped characters aren’t counted going into the parser.Is that the case? A couple of large functions I had checked while doing the building of the hints for functions, so I know when I did it, it was within those character(byte) counts. While compiling the different modules into the final file I noticed it looked a bit larger, and checked the size via a character count website…where it reported that, the working in NPP function size was more than the limit.
Has the size been increased, or does the parser just not count the extra characters needed to escape the angle brackets?
Lee
-
That’s getting deep into implementation details. If the 2200 character version worked for you, it is likely that the &-entities are converted to real characters before the byte-limit is hit, but I cannot guarantee it.
Someone who is pushing up against that limit would be well-advised to be wary, and see if there is any way to trim down the text – and maybe even seek out the source code for that portion, and see what order events occur, and exactly when the character limit is hit.
-
@peterjones said in Auto-Completion Is this Legal?:
That’s getting deep into implementation details. If the 2200 character version worked for you, it is likely that the &-entities are converted to real characters before the byte-limit is hit, but I cannot guarantee it.
Okay, this make sense in hindsight, but as your next point makes…
Someone who is pushing up against that limit would be well-advised to be wary, and see if there is any way to trim down the text – and maybe even seek out the source code for that portion, and see what order events occur, and exactly when the character limit is hit.
I was testing it, that’s how I knew I was within limits before I did the conversion to escaped characters, per your recommendation. I did it, even though it worked, on the off-chance that future parsers change their behavior with regards letting that character survive in quotes, and hence the increased size is what caught my attention. The stock dBASE syntax notation use of angle brackets
Indicates an argument that you must supply
meaning, there were a lot of them in those multiple overload, parameter and entries.Thanks for what insight you could provide.
Lee
-
@lycan-thrope
As a note, if anyone else has need for it, I used this character count website to check it out, so it was open in the tab next to the NPP documentation while writing them so I could check the count supplied against the count I could have. : -)Lee
-
@lycan-thrope said in Auto-Completion Is this Legal?:
I used this character count website to check it out,
Any reason you didn’t just use Notepad++ status bar? It shows the size of any single-region selection:
And if you were trying to get the data on multiple text entries in the same function, you would have had to copy them from their attribute locations into the website, so why not just copy them into a new tab in Notepad++? (And a new tab makes it even easier, since it already gives the length of the whole tab.)
-
Umm…because I didn’t know it did that? :-) I knew about the character count in the file, but had never noticed the ‘sel’ part…doh! Aside from that, I still had the manual open and could check when it gave me the count, since I don’t remember everything, I could check the manual. :-)
Thanks, btw.
Lee
-
@lycan-thrope
Incidentally, this is normally what I see, but I see now when I’ve selected something, it comes up. ::sigh:: so many options, not enough reading. :-)Lee
-
@lycan-thrope
Peter, et al,
I’ve finished with the package for the moment. I’ve given it to our community on our newsgroup to try and work with, and I have a few other things I’d like to do, like include more keywords of stock classes, objects, properties, events, etc, and tighten up and improve the FunctionList parsing (remove the parens, from(this)
, and the larger names), and possible do a version for our older procedural version of dBASE, which actually is still being used in older programs and in other countries.That said, the question becomes, since it’s not a .dll to be included in NPP proper, how does one get this setup (of three separate files, two named the same)to be used by anyone looking for a dBASE flavor for NPP, other than our newsgroups?
Lee
-
@lycan-thrope
To be clear, I have no idea how to use github, a pull request, etc. So I’m really novice in this area. As a note, the Autocompletion and functionList files (with the same name) seem to be the problem with just zipping up the files and since I have no way of knowing where users have their installations, my assumptions about 64 bit/32 bit/Standard install and stand alone install have all been pushed to the side as I tried to explain where to install the files, and am not sure what I would have to do to get a .zip version to do it automagically. I know, there’s a lot I don’t know…tell me something I don’t know. :-)Lee