this is my code:
TAG POS=82 TYPE=P ATTR=* EXTRACT=TXT
TAG POS=85 TYPE=P ATTR=* EXTRACT=TXT
TAG POS=86 TYPE=P ATTR=* EXTRACT=TXT
'clean the extracted data:
SET replies EVAL("'{{!EXTRACT}}'.replace(/[\\$|'[EXTRACT]'|#EANF#]/g, '');")
'below code is suppose to put the extracted replies into the summerizer box
TAB OPEN
TAB T=2
SET !ERRORIGNORE YES
URL GOTO=http://www.summarizing.biz/best-summarizing-strategies/article-summarizer-online/
TAG POS=1 TYPE=TEXTAREA FORM=ID:summarizingform ATTR=ID:draft CONTENT={{replies}}
EVENT TYPE=MOUSEUP POINT="(1140,899)"
PROMPT "Please enter the captcha:" !VAR1
TAG POS=1 TYPE=INPUT:TEXT FORM=ID:summarizingform ATTR=ID:sum_secure CONTENT={{!var1}}
SET !ERRORIGNORE NO
TAG POS=1 TYPE=A ATTR=ID:summar_btn
'Prompt and ask for the rephrased summery
PROMPT "type the rephhrased summery" !VAR2
TAB T=1
I'm trying to remove "[EXTRACT]" and "#EANF#" from the extracted data but when I use this code:
SET replies EVAL("'{{!EXTRACT}}'.replace(/[\\$|'[EXTRACT]'|#EANF#]/g, '');")
it removes all capital "E X T R A C T" from the text. for example if I have the word "Report" in my extracted data it becomes "eport" after going through the Eval.
please help me.
thanks in advance
here's the right eval command in case someone is interested:
SET replies EVAL("'{{!EXTRACT}}'.replace(/(EXTRACT|#EANF#)/g, '');")
oh my god this Eval thing is so powerful...opens a whole alot of possibilities for you...
Maybe not the best, but a solution,
1. Try to set the complete text as a var, f.ex:
SET !VAR1 and here goes your EXTRACTED TEXTS ETC.
2. Paste the text somewhere into an online notepad in a second tab, ghostbin, piratepad, ...
Record with experimental mode how you edit the text WITH the keyboard.
Set the edited text again as your new !VAR1 and use !VAR1 as your whole text
As said, not best solution etc. but could be one.
One question i still have, why dont you simply delete the words "[EXTRACT]" and "#EANF#" ?
Related
I know we can use "word_wrap": "auto" in the User settings to make Sublime Text 3 auto wrap text, but how can I make it break a long word when wrapping?
In a sentence like:
a long word aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
I want it to
a long word aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
aaaaaaaa
but not:
a long word
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
First, I saw advice to add "auto_wrap_break_long_word" : false, to the setting file, but it made no sense to me.
And then, I get advice from comments by using Sublime Wrap Plus
However, it is not what I want.
The Readme of Sublime Wrap Plus says:
Enhanced “wrap lines” command for Sublime Text 2 or 3. This is for the manual hard line wrap command. It does not affect the automatic soft line wrapping.
But what I want is not “HARD line wrap” because it will add real some line breaks and change the text file. And what I want is to break long word in “SOFT line wrap”(which will not change texts but only change how it looks)
In fact , I've tried to install the Sublime Wrap Plus package and set "WrapPlus.break_long_words":true in Preferences >> Settings — User.
But nothing changed about my SOFT line wrap.
THANKS for all advice anyway!
Recently I wrote a text file without a file extension with the vim text editor and got text highlightning for all words between singel quotes like 'word' and all words ending with a colon like word:
I like this kind of highlightning.
But because I havent typed any command, which usually starts with ESC :command, I was surprised how this could happen.
Is there a command to display the actual syntax highlight which is in use?
I already have tried the command :set syntax=php which seems simliar only with different color for words like word:
Does anyone have suggestions?
Try entering the command
:echo &syntax
This will display the value that the syntax variable has been set to.
set option=value "set the option with value
set option? "read/print the current value of the option
set option! "set the option with opposite value, like set nu and set nu!
the option value is also saved in variable &option so you can read in script way.
When I am editing a LaTeX file using Vim-LaTeX and want to reformat a section of text that is in a \caption{} I get overhangs or underhangs - I am not sure what to call them. I first select the text in the caption then use "gq" to reformat it. After reformatting the caption looks like:
\caption{The problem is that when I reformat the text
in a caption the text on each successive line
begins further and further to the left until it begins
at the first space of the line.}
what I would hope the result would look like would be something like:
\caption{The problem is that when I reformat the text
in a caption the text on each successive line
begins further and further to the left until it
begins at the first space of the line.}
I hope the formatting in this post remains true to what I typed in, but I tried to describe the problem in the first example caption. The second should be left justified.
Does anyone know what I need to do to fix this? I am assuming that there is a setting that I need to change, but I have not been able to figure out what it is.
The gq command formats based on 'formatexpr' or 'formatprg'. You can start by checking the values of these options with :se fex? and :se fp?.
From looking through the vim-latex plugin it never sets these options, so this is likely set by your other plugins or vimrc. You can find out exactly where an option is set by using :verbose.
I have a regex expression that I use regularly to find specific lines in my codebase.
Let's say the expression is
\s*<search keyword> = myClass(.*)
with <search keyword> being the part of the regex that changes depending of the search.
How can I make entering such a search as fast as possible in ST3?
I tried using snippets that at first sight seem to fill my need as they enable to set the location where the text editing will be resumed, so I could just type <snippet alias><TAB><search keyword> in Find: field to trigger the search.
Alas no, snippets are disabled in search fields (only accessible in main text window).
You can use snippets in search bar, for example:
<snippet>
<content><![CDATA[
\s*$1 = myClass(.*)
]]></content>
<tabTrigger>search</tabTrigger>
<description>Search snippet</description>
</snippet>
BUT you can only expand them with CTRL+Space. Tab key for snippet expansion does not work in search field.
Btw: This works for me in Sublime Text 2. But it should work in Sublime Text 3 too
Let's say I have some HTML:
<tag>Here is a bunch of text which is pretty long.</tag>
My cursor is on H.
I want to add some more text after the period. That is, I want to append text inside of the tag.
Right now, I'd probably $ to the end of the line and then b until I get to the .
The end of the text inside the tag is not predictable, so I can't use f..
What's the fastest way to get to the end of the text inside a tag?
This might not be the best way but one way to do this is to use vit to visually select the inner tag block. And then type A to append to the visually selected region.
So the command is
vitA
And if you just want your cursor at the end of the tag just use
vit<esc>
I would do t<a instinctively.
But I like FDinoff's method better.
It's not one move but this gets the work done.
Assuming that you are in normal mode. Enter the following commands
vatA
What this does is, it visually selects the block including the tag and appends at the end of the line.