Quotation

Applications, Games, Tools, User libs and useful stuff coded in PureBasic
AZJIO
Addict
Addict
Posts: 2191
Joined: Sun May 14, 2017 1:48 am

Quotation

Post by AZJIO »

Quotation

Download: yandex (Windows/Linux)

Screenshot on Linux
Image

Saves selected texts quickly.

1. Select the text and press Ctrl+J
2. A preview window will appear with the inserted text. Use the keyboard arrows to select where to save. Esc - cancel, Enter - Ok.

Currently there are 2 save modes. The first mode saves to a shared file, the second mode saves to separate files. You can add the number of places to save by specifying a section in the ini file.

Now works in Linux, but the hot key is assigned in the shell of DE.

ini file

Code: Select all

[set]
SelLst=0 ; Choosing item in the list
HotkeyCode=586 ; Hot key code
MaxSize=500 ; The maximum file size in KB. If it exceeds, then the old is copied to the new file with the date, and the current is cleaned and written again
Preview=1 ; preview the fragment before saving and select the save section.
Clipboard=0 ; if 0, then capture the selected one, if 1, then capture the clipboard.
ClrFnt=AAAAAA ; The color of the text in the preview
ClrBG=3F3F3F ; Background color in the preview
Signal=C:\Windows\media\Windows - exclamation.wav ; a successful save signal
Editor=C:\folder\AkelPad.exe ; file editor
fm=explorer.exe ; file manager for opening folders

[Quote] ; all sections except [set] are the saving section shown in the preselection for saving selection.
mode=1 ; save mode. "=1" - single-file
path=Text\Quotation.txt ; The path to the quote saving file (empty, relative and absolute)
separator=\r\n\r\n=== %d %t ====\r\n\r\n ; The separator between quotes. Variable dates %d and time %t
wstr=0 ; File encoding (0 - UTF-8, 1 - Ascii, 2 - Unicode)
bom=1 ; Adds BOM
edit=0 ; If 1, the text can be edited in the preview window and will be saved from the editor window.
TitleBtwn=<title>_|_<\title>_|_\r\n\r\n ; Adds a header by taking from the content between the tags.

[PureBasic]
mode=2 ; save mode. "=2" - save to separate files
folder=%yyyy.%mm ; is a way of specifying the folder, in this case year and month.
path=PureBasic ; path where folders will be generated and files in them
Ext=pb ; file extensions
wstr=0 ; File encoding (0 - UTF-8, 1 - Ascii, 2 - Unicode)
bom=1 ; Adds BOM
edit=0 ; If 1, the text can be edited in the preview window and will be saved from the editor window.
run=0 ; If 1, the file will be opened in the editor.
genname=0 ; filename generator. 0 - name request, 1 - date and time is the file name, 2 - counter from 1 onwards. If the name of an existing file is specified at =0, an index will be added, e.g. name_1, name_2, etc.
Last edited by AZJIO on Fri Mar 07, 2025 3:50 am, edited 5 times in total.
AZJIO
Addict
Addict
Posts: 2191
Joined: Sun May 14, 2017 1:48 am

Re: Quotation

Post by AZJIO »

Update. v0.3
BarryG
Addict
Addict
Posts: 4173
Joined: Thu Apr 18, 2019 8:17 am

Re: Quotation

Post by BarryG »

What is this for?
AZJIO
Addict
Addict
Posts: 2191
Joined: Sun May 14, 2017 1:48 am

Re: Quotation

Post by AZJIO »

More than once they were asked to write a program to copy the selected text and save it to files (link1, link2, link3). I used to do it on AutoIt3, now I did it on PureBasic. But now it is possible to save to separate files.

For example, you select a code fragment on a forum and press a hot key, this code is automatically saved to a file with the requested name, or a date or a counter is used. Saved in folder 2022.08, but you can set a different format. You do not need to do it by hand when creating a file, open and copy and save. Everything is done automatically.

You can copy links to the linkbase. In general, you save any information to a file. You just need to use the up arrow or down arrow to select the save location and press Enter. You can also save without preview.

The archive has a help file (UTF-8) with a detailed description, you can translate it in Google.
AZJIO
Addict
Addict
Posts: 2191
Joined: Sun May 14, 2017 1:48 am

Re: Quotation

Post by AZJIO »

Updated for Windows
Post Reply