I entered this in user settings "auto_complete_selector": "source, text" but autocomplete does not launch.
I get this instead.
Error trying to parse settings: Unexpected trailing characters in C:\Users\shelly\AppData\Roaming\Sublime Text 2\Packages\User\DictionaryAutoComplete.sublime-settings:1:25
I would guess that you added this line outside of the braces.
You need to have it inside so something like
{
"auto_complete_selector": "source, text"
}
Related
I want to read a JSON text string that contains control characters into a razor component Blazor variable.
The Blazor variable is:
<p>#Product.Description</p>
I want the JSON text to include control characters that enable the string to be formatted for display. I have used HTML <br> tags in an example JSON text string showing what I want below.
"Description": "This is a detailed description.<br> There is also a list of bullet points, for example:<br>● Helpful hints;<br>● Links to other sites.”
Unfortunately, the <br> tags are rendered as text and not line breaks. I have also tried \r\n and various other escape sequences but are all rendered as text.
Can anyone tell me how to pass actionable control characters from a JSON text element to a razor component Blazor variable please?
<p>#((MarkupString)Product.Description)</p>
I want word wrap off for everything except plain text.
I've added "word_wrap": false to my Preferences.sublime-settings and then created Plain Text.sublime-settings.
Plain Text.sublime-settings is in ...AppData\Roaming\Sublime Text 3\Packages\User and contains:
{
"word_wrap": true
}
However, the pain text file remains unwrapped.
To set settings for a specific language, do the following:
Open up any file with that syntax type
Go to Preferences –> Settings–More –> Syntax Specific–User
This should open up the correct file for your language-specific preference settings.
Sublime text is case sensitive on the file name.
Plain Text.sublime-settings <== Bad
Plain text.sublime-settings <== Good
`
I'm using Emmet in Sublime Text 3.
After executing a{display text}, you get
display text
What I'm trying to do is get the cursor to jump to after the close </a>, after I've pasted in the url. I'm trying to simulate Sublime's autocomplete $0 behavior, like
display text$0
I am looking through snippets.json, but I'm not getting it. The only "a" entry is in the "abbreviations" object, and contains only the open tag:
"a": "<a href=\"\">",
I've not edited any Emmet tags before, and I thought this might be a good first one to try.
Any ideas on how this might be possible?
There's a built-in Emmet setting that does this for all tags:
This is in C:\Users\jeffy\AppData\Roaming\Sublime Text 3\Packages\Emmet\Emmet.sublime-settings
// If set to `true`, Emmet will automatically insert final tabstop
// at the end of expanded abbreviation
"insert_final_tabstop": false
I duplicated it to C:\Users\jeffy\AppData\Roaming\Sublime Text 3\Packages\User\Emmet.sublime-settings
and changed it to true. It does exactly as I want. Well, it still goes to the display text, even if there already is display text. Then it goes to the end. But close enough!
I am having problem displaying a text with multiple lines. For example, the user can type their text in a textarea in a registration form and the text can be of more than one line i.e. he can hit the Enter (return) key to insert line breaks.
On one page, if I want to show the text that he typed and I use a textarea to display (with EL), it displays the way user had entered initially.
But on another page I need this text be shown in paragraph format (using <p> tag). On this page, when I display the value that the user entered while registering, it does not have the line breaks i.e. it displays in a single line rather than with multiple lines as was entered by the user.
I already tried displaying the text through EL within a <p> tag and using a <c:out> tag of the JSTL within a <p> tag.
Some code that I tried:
Trial-1:
<p>${product.description}</p> //Doesn't show line breaks
Trial-2:
<p><c:out value="${product.description}" /></p> //Doesn't show line breaks too
How can I fix this?
Did you view the source sent to the browser ? Please try
<p><pre>${product.description}</pre></p>
Right now I can think of something as to replace the \r\n sequence in the product.description string with <br /> with help of scriptlets or fn JSTL (function) tag
Idea Courtesy: SO Answer.
I am using Rockmongo as the UI, and I am trying to save something every similar to this.
text text's text. <p>text this is where the text goes</p><h1>haha</h1>
Now I am not sure if it is the .,' or even the ? <p> etc.
I was unable to reproduce this. Here is what I tried in the JavaScript shell:
> db.text.save({_id:1, text:"text text's text. <p>text this is where the text goes</p><h1>haha</h1>"})
> db.text.find()
{ "_id" : 1, "text" : "text text's text. <p>text this is where the text goes</p><h1>haha</h1>" }
The line was saved successfully. Are you surrounding the text string with double quotes " ? As bfavaretto mentioned, the issue could be from the single apostrophe in your string. The following will not work:
> db.text.drop()
true
> db.text.save({_id:1, text:'This is text with an extra ' apostrophe.'})
...
...
> db.text.find()
>
As you can see, the above document was not saved because the string was not properly formatted. In fact, the JS shell never even executed the command.
Mongo should be able to save a string containing all of these characters. If you are still having issues, perhaps this could be an issue with RockMongo? (Unfortunately, I am not familiar with this program.) A simple way to troubleshoot is to test saving each unique character one at a time, and see which character causes the issue. Hope this helps!