As I think many of you are aware, ZEP has added a new ability in PICO where you can couch your code into a series of helpful TABS.
As you can see, there are  tabs above. 0, 1, and 2.
The problem is if you try to SEARCH for something with CTRL-F. If you are on the tab where it can be found, then it will show up.
But if NOT, say, you are on tab zero and what you are looking for is on tab one, then the search will FAIL and not find what you were looking for.
This will be a problem especially for those people who want to look at source code from others and are searching through to see how it functions, and then failing on a search for what is most definitely an active and written function, just not in that particular tab.
Once I found I couldn't search for my own functions, I went back and changed my code so it's all under the main tab.
A shame you can't read in text files in PICO. I could easily write a de-tabulator, that is a program which saves a new .P8 file that links all your functions back to the original tab.
You might be able to do it manually though. Let me see ...
Yep, that's not so bad. Okay, bring up your .P8 file in wordpad. If you bring it up in Notepad I found it can mess up.
Okay, from here, REPLACE all of "-->8" with nothing.
Save as new .P8 file. Bring it up, all your functions should be back under one roof, the main tab.
Maybe zep could allow us to toggle between flat and tabbed modes. Then you could search the whole document or the current tab.
In flat mode, either display the tab-creating comments as-is (easy), or show the tabs inline (harder but nicer):
(the tab shown in the top bar would be the one currently at row 0 in the text area)
If you're going this route, Felice, how about this ?
I know GFA could do this, it could FOLD functions, so while there would be code for each of your functions, you can hit [F11] on each of them and minimize them to look like this:
function _init() function _draw() function _update() function additup(a,b)
Your functions would still be there. You could press [F11] to return each of them in return. But you could still run your code with these functions minimized.
Maybe change the ink or background color of the folded function.
I'm expanding my thread to include this request - and your own request - the one you just wrote above, Felice. Remember ? :)
I don't think ZEP is going to read only the title and go from there. But yes, it would be an advantage to all of us to get this difficulty repaired.
If we somehow both get bonus flat and tabbed modes as well as folding, I'll be certainly happy with that.
I just know that when I was a lead on projects, I hated requests or bug reports that had multiple line items in them. The dialogue would always get muddy.
(My suggestion was a solution to your problem. Folding has nothing to do with your problem.)
Alright Felice. C'mon, reel it in. Claws retracted, both of us now. =Mrow!= :D
My suggestion would satisfy (at least to me) the problem of multiple tabs and the inability to search through the entire code.
The solution that would work best for me is to have no tabs at all and the ability to fold them so as to keep them organized - as I believe the purpose multi-tabs had yet now hinders.
Your solution would work too, but as screen space is vital to the programmer, I wouldn't want excess data on the screen such as the red bars with the digits presented.
Just the simple "FUNCTION()" vertically laid atop each other - square brackets to denote folding is fine.
"Editing operations like undo, search and selections apply per-tab. It isn't currently possible to search across tabs -- this will be added later along with improved error messages that span multiple tabs."
- zep in the 0.1.11 announcement post
[Please log in to post a comment]