Skip to content

Commit e61f52a

Browse files
committed
Update README.md
1 parent 764009e commit e61f52a

File tree

1 file changed

+33
-89
lines changed

1 file changed

+33
-89
lines changed

doc/README.md

Lines changed: 33 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,12 @@
1818
- [Grammar Local Settings](#grammar-local-settings)
1919
- [Show Command](#show-command)
2020
- [Force RPC](#force-rpc)
21-
- [Quick Command Overview](#quick-command-overview)
21+
- [Quick Functionality Overview](#quick-functionality-overview)
22+
- [A Bit Of Advice](#a-bit-of-advice)
23+
- [A Small Remark](#a-small-remark)
2224
- [Selection Queries](#selection-queries)
25+
- [Operations](#operations)
26+
- [Collection Queries](#collection-queries)
2327

2428
<!-- /MarkdownTOC -->
2529

@@ -46,6 +50,8 @@ Some quick links to the various documentation files
4650

4751
## General Remarks
4852

53+
54+
4955
### Caster Version Supported
5056

5157
Currently Caster 0.5, 0.6, 1.0 are all supported but it is my recommendation that you update to the latest master or anything >=1.0, as 1.0.0 introduced various improvements and sooner or later support for the two older versions of Caster or will be dropped.
@@ -405,35 +411,32 @@ Forces RPC no matter what. Might be useful when host is windows and guest is
405411

406412

407413

408-
## Quick Command Overview
414+
## Quick Functionality Overview
409415

410-
Here we will briefly go over the commands offered.
416+
Here we will really really briefly go over the functionality offered. you can find more extensive documentation in the outgoing links.
411417

412-
Before we get started, a small general remark:
413-
```
414-
tip: if you do not know what to say, say smart :P
415-
```
418+
### A Bit Of Advice
416419

417-
because virtually every command starts with the keyword smart!
420+
It is my recommendation,
418421

419-
```python
420-
"smart <big_roi> [<big_roi_sub_index>]"
422+
Also keep in mind that whenever you find anything ending in `index` that is an integer!
423+
424+
### A Small Remark
421425

422-
"smart <color> [alternative]"
423-
```
424426

425-
This was chosen in order to minimize chances of collision with other commands on your system. However, because for a variety of commands, omitting the keyword smart makes them more convenient and easier to speak
426-
you may find the smart keyword in brackets
427+
Before we get started, a small general remark , virtually every command starts with the keyword smart!
427428

428429
```python
429-
"[smart] alternative <alternative_index>"
430+
"smart <big_roi> [<big_roi_sub_index>]"
430431

431-
"[smart] paste back [<paste_back_index>]"
432+
"smart <color>"
432433

433-
"[smart] paste <color> back"
434+
"[smart] alternative <alternative_index>"
434435
```
435436

436-
if there are conflicts with other commands, try to remove those brackets (making smart not optional). Furthermore, I think it is best not to put brackets in cases where I haven't.
437+
This was chosen in order to minimize chances of collision with other commands on your system. However, because for most commands, omitting the keyword smart makes them more convenient and easier to speak you may find the smart keyword is optional in some commands.
438+
439+
if there are conflicts with other commands, make it not optional/edit to suit!
437440

438441
After the small remark let's get started!
439442

@@ -523,55 +526,30 @@ I do not expect these examples to make this distinction clear, just keep this in
523526
Details vary but that is the. spirit! Ok , what else?
524527

525528

526-
### Alternatives
529+
### Operations
527530

528-
As you can see, these commands select some ROI (region of interest) and generate alternatives. These alternatives are shown to the user in an output panel on the bottom of the screen and the top ones get highlighted in the code as well.
531+
As you can see, these commands select some ROI (region of interest) and generate alternatives. what can we do with those alternatives?
529532

530-
We can select one of those alternatives with the alternative rule which comes in two variations:
533+
the plug-in ships with a variety of commands that you can run after a selection query that enable you to perform various operations with the main results /one of the alternatives, in certain cases multiple of them or even work with the point origin of the selection query as well!For example
531534

532-
```python
533-
"[smart] alternative <alternative_index>"
534-
535-
"smart <color> [alternative]"
536-
```
537-
![](./gif/d1.gif)
535+
we can select them
538536

539-
alternative_index is an integer
540-
```python
541-
(Tip : index --> integer)
542-
```
543-
whereas color is an adjective corresponding the color highlighting:
537+
![](./gif/op5.gif)
544538

545-
```python
546-
Choice("color",{
547-
"red":1, "blue":2, "green":3, "yellow":4, "orange":5,
548-
}
549-
)
550-
```
539+
Or perhaps delete them
551540

552-
### Paste Back
541+
![](./gif/op10.gif)
553542

554-
But why would we want to select some text in the first place? Other than editing it, maybe to copy it and paste it somewhere? Very likely where we are currently working? Well, the paste back command allows just that!
543+
or we can swap them
555544

556-
![](./gif/d2.gif)
545+
![](./gif/op13.gif)
557546

558-
As you can see it comes in two formats:
559-
```python
560-
"[smart] paste back [<paste_back_index>]"
547+
Or we can paste them
561548

562-
"[smart] paste <color> back"
563-
```
564-
565-
If no alternative is specified the main result is pasted back!
566-
567-
Please also pay attention to the following:
568-
569-
![](./gif/d3.gif)
570-
571-
That is you can use successive selection queries and paste back will insert in your original starting position!
549+
![](./gif/d2.gif)
572550

551+
Furthermore by using the prefix `operation` that appears at the start of selection queries
573552

574-
So we can select some basic stuff and we can insert it where we are writing. What elae can we do?
575553

576554
### Collection Queries
577555

@@ -585,41 +563,7 @@ Collection Queries try to address this issue. These collect the text of interest
585563

586564
![](./gif/d4.gif)
587565

588-
you can collect a variety of things:
589-
590-
```python
591-
Choice("collectable",{
592-
"(variable|variables)":"variable",
593-
"( parameter | parameters)":"parameter",
594-
"(module|modules)":"module",
595-
"imported (value|object)":"import value",
596-
"function ( name |names)":"function name",
597-
}
598-
```
599-
please note that these items are collected from the whole source code.
600-
601-
### Insert Item
602-
603-
These "items" can then be inserted in the current cursor position by means of the
604-
605-
```python
606-
"(smart insert|insert item) <item_index>"
607-
```
608-
command. Item_index specifies which item from the collection you want
609-
610-
![](./gif/d5.gif)
611-
612-
### index collectible
613-
614-
certain collectible items such as variables and parameters can be index collected by means of a query like
615-
616-
```python
617-
"[smart] variable <collect_index>"
618-
```
619-
In such a case, items will only be collected from the current function and in item will be inserted
620-
based on the index specified and their order of appearance
621566

622-
![](./gif/d6.gif)
623567

624568

625569

0 commit comments

Comments
 (0)