Posts: 1,616
Threads: 157
Joined: Apr 2022
Reputation:
77
So today I figure on improving the file handling routine. My goal is to bring in a collapsible display system, so snippets can be stored as headers like [DO:LOOP - Standard] or [DO:LOOP - Indexed] etc. Click the header and it would paste in...
Code: (Select All) i = 0
DO
i = i + 1
LOOP until i =
After the paste, just fill in the missing blanks.
Pete
Posts: 1,616
Threads: 157
Joined: Apr 2022
Reputation:
77
11-09-2022, 11:48 PM
(This post was last modified: 11-09-2022, 11:48 PM by Pete.)
@Jack
And all..
Updated Sam-Clip with some nice features. Say you have 20 lines of code you'd like to save to be able to paste into other projects. Say you would recognize it as [Mouse Controls]. So now you can highlight your 20-lines of code, and when you release the left mouse button, Sam-Clip will ask you if you want to collapse your lines into a single header entry. Click "Y" for yes and then type: "Mouse Controls" and press Enter. Anytime you need that pasted into a program, just open Sam-Clip, highlight that header then click where you want it inserted in your IDE. That's it, all 20-lines of the code will appear.
Pete
Posts: 1,616
Threads: 157
Joined: Apr 2022
Reputation:
77
Finished my todo list of Sam-Clip features. Next I need to spend some time to debug, as new features can introduce new bugs.
I find the easy way to keep track of things these days is to put a pseudo block REM in the top of my code...
Code: (Select All) $IF THEN
File menu.
(X) Middle mouse button to paste today's date.
(X) Clipboard paste ability to blank space or heading input line instead of typing.
(X) User input to blank space.
(X) Place Crtl / hold option in settings.
(X) Place snooze toggle / hold in settings.
(X) Translucent window option.
(X) Font selection.
(X) Font sizing.
(X) Settings tab functions.
(X) Help.
(X) Tab system.
(X) Blank a file with only spacer entries when a deletion is made.
(X) Toggle/Click instead of hold key to SLEEP Sam-Clip.
(X) Copy option for keyboard copy in IDE.
(X) Spacer / crop.
(X) Recycle Bin.
(X) Restrict off-window button release to highlighted lines only.
(X) Disable on minimize.
(X) Create scrolling.
(X) Add margins.
$END IF
I also put a SUB SamDocumentation in the program, to add notes. Getting old is soooooo much fun. When I'm 90 I'll probably have two screens of todo list and three for the documentation, while I'm pecking away at my Hello World! app. Right now I'm at about 1,500 lines. I can keep about 2,000 in my head these days. That's a lot less than the 8,000 I could keep straight a few decades ago.
Oh well, if I get it all working this weekend, I'm going to start the next week off by doing a small rewrite. While putting it together I came up with a better functional appearance I want to switch to.
Pete
Posts: 336
Threads: 24
Joined: Apr 2022
Reputation:
19
Pete
what happened to your first post?
when I paste it in the QB64 IDE all indentation looks like this: ááááááá
Posts: 1,616
Threads: 157
Joined: Apr 2022
Reputation:
77
(11-19-2022, 01:13 PM)Jack Wrote: Pete
what happened to your first post?
when I paste it in the QB64 IDE all indentation looks like this: ááááááá
It doesn't do that on mine. I have my IDE set up to auto indent, and when I paste to it, it shows up left justified, and then immediately indents the code pasted, without any visible leading characters.
I made Sam-Clip remove indentations when pasting into the clip utility, so pasting from the utility into the IDE would not have any leading characters. An IDE, set up with the auto indent feature, would do the indenting.
I'm using version 3.30. If you are using the latest version I may have to check and see if something has changed.
Oh, if your Sam-Clip window by any chance shows text with indentations, it shouldn't. Please let me know if this is the case so I can figure out how a paste into Sam-Clip didn't remove document indentation. Right now it is set up to remove CHR$(9) TAB, leading spaces, and CHR$(0). I did not include CHR$(255) in that trim function.
Thanks,
Pete
Posts: 300
Threads: 57
Joined: Apr 2022
Reputation:
56
Works OK for me here, Pete, under Windows 7 32-bit. I also get all the ááá insted of indention spaces when copying/pasting the code. Maybe it's the font your using in your IDE? I dunno. Luckily the QB IDE "Change' feature works well and removed the 5000+ characters with one click.
- Dav
Posts: 1,616
Threads: 157
Joined: Apr 2022
Reputation:
77
11-19-2022, 05:27 PM
(This post was last modified: 11-19-2022, 05:27 PM by Pete.)
(11-19-2022, 05:06 PM)Dav Wrote: Works OK for me here, Pete, under Windows 7 32-bit. I also get all the ááá insted of indention spaces when copying/pasting the code. Maybe it's the font your using in your IDE? I dunno. Luckily the QB IDE "Change' feature works well and removed the 5000+ characters with one click.
- Dav
@Dav
Mine is setup as: C:\Windows\Fonts\lucon.ttf Font-Size = 20. What is your setting? I'll switch and give it a try.
Pete
Posts: 300
Threads: 57
Joined: Apr 2022
Reputation:
56
I'm using the same font, size of 24. Perhaps the forum code box screwed it up somehow? How about trying to repost the code again and see it occurs again. First time I've seen all those ááá's in posted code here.
- Dav
Posts: 1,616
Threads: 157
Joined: Apr 2022
Reputation:
77
This is a bit puzzling. I copied the code from the code box this morning, to test this when Jack mentioned it, and it worked fine for me.
I have to do other things at the moment, but I tried copying 200 lines of code from the IDE and put it in a header. Named the header "Test" and clicked it to place it back in the IDE, it worked. No unwanted characters, so if you tried the same, or just a simple copy / paste of a few lines and it produced those characters, maybe I will have to try the latest QB64 version 3.4, if that's what you both are using.
Thanks,
Pete
If eggs are brain food, Biden takes his scrambled.
Posts: 336
Threads: 24
Joined: Apr 2022
Reputation:
19
11-19-2022, 06:49 PM
(This post was last modified: 11-19-2022, 06:54 PM by Jack.)
Pete
I normaly use the FireFox web browser and the malady happens when using FireFox, just now I tried the Wndows Edge Browser and all is well
however, the code posted by PhilOfPerth https://staging.qb64phoenix.com/showthread.php?tid=1133 has no problem in FireFox, so not all the fault is the browser's, something else is at play
-- edit -- I wonder what browser @PhilOfPerth used when he posted the code?
|