SikuliX IDE to use dotted characters - character-encoding

I use SikuliXIDE 1.1.4-SNAPSHOT with Ruby scripting and have strings, which contains following dotted characters: áéöüóőúű. I try to use paste() method to put it to a field.
I found solution ALT key codes, but I don't know where these characters located in string.
I found paste(unicode()) method, but it isn't present in newest SNAPSHOT version.

try using the below code
paste(myPathname.force_encoding("Windows-1252").encode("UTF-8"))
please refer the link for more info
hope you get the solution....

Related

carat and New line issues using NHAPI tool in .NET

I'm using NHapi v22 tool for sending HL7 messages. Issue is I'm not able to create component separator(^) and new line. Please tell me how to code for it in C#.
Following is the code:
MSH|^~\&|xyz|xyz|FLOW|FLOW|201601201525||ADT\S\A04|201601201525123456789|P|2.3|||NE|NE
I need to get like this- ADT^A04
I believe the issue here is that \S\ is an escape character for ^ (component separator). Your message should contain an actual component separator with the actual ^ in it, not the escape character.
"ADT" should appear in MSH-9-1 and "A04" should appear in MSH-9-2 as opposed to how I suspect you are doing it with "ADT^A01" in MSH-9.
Does this help? Please feel free to contact me directly if you need more specialized advice.
edit: I don't normally use NHapi but I suspect you may need to do something along this line:
terser.set("/MSH-9-1", "ADT");
terser.set("/MSH-9-2", "A01");
as opposed to something you might be doing
terser.set("/MSH-9", "ADT^A01");

Xamarin ios - import library

I need help importing a library to Xamarin. I included the library and inserted it into a new folder named BarcodeScanner, and the name of the library is libBarcodeScanner.a.
gcc_flags "-L${ProjectDir} -lBarcodeScanner -force_load ${ProjectDir}/libBarcodeScanner.a”
But it shows an error:
Error: Could not parse additional mtouch arguments: No matching quote found.
What should i do ?
Do i need to create a binding project to use a library like BarcodeScanner ?
Error: Could not parse additional mtouch arguments: No matching quote found.
That does not look like a Xamarin.iOS (mtouch) error message. Those start with a MT prefix followed by 4 numbers, e.g. MT2001. Could it be Xamarin Studio giving you this error ?
What should i do ?
Review the flags: are they identical to what's pasted above ?
No matching quote found. makes is sound there's an extra quote in there. Maybe one of the " is wrong (e.g. a autocorrection giving you a smart quote) ?
Or maybe your project directory (replaced from ${ProjectDir} contains a quote character ?
Also can you edit your question to add which version of Xamarin Studio you're using ?
Do i need to create a binding project to use a library like BarcodeScanner ?
No, but it's the preferred ways to link static libraries. Using a binding project removed the need to add Additional mtouch arguments inside every projects and every build configuration (e.g. Debug, Release...) of your applications.
I will answer my own question, maybe it will help someone. I declared in my MainController that i needed:
using MonoTouch.CoreVideo;
using MonoTouch.CoreMedia;
using MonoTouch.CoreGraphics;
using MonoTouch.CoreFoundation;
And after that i referenced only the static library with:
-gcc_flags "-L${ProjectDir} -lBarcodeScanner -force_load ${ProjectDir}/libBarcodeScanner.a"
#poupou's "maybe" was spot on, but I'll be pedantic and explain exactly.
Look closely at this line I just quoted from your original question. I've marked it down using code (four spaces prefix per line), and broke it into two lines. Nothing else has been changed. Hopefully the error should be obvious now:
- gcc_flags "-L${ProjectDir} -lBarcodeScanner
-force_load ${ProjectDir}/libBarcodeScanner.a”
Essentially, you used different types of double quotes. The first double-quote character above is Unicode 0x0022, which is the regular Quotation Mark. The second double-quote character above is Unicode 0x8221, or Right Double Quotation Mark. It might be that you had copied & pasted all or part of the line above from a web page, rather than typing it in.
For command-line processing, mixing your styles of double quotes simply won't work. You'll need to use balanced regular quotation marks, as you wrote in your own answer just now (but might not have specifically noticed?) FWIW, the right- and left- variants of the quotation mark are usually used for word processing, web pages, etc. where the style aesthetic matters.
Since you didn't use code-markup when quoting that line originally (while I noticed you did, in your recently posted answer) it looks like Stack Overflow "helpfully" tried to render the quotes as similar in style, fooling us into looking elsewhere for the problem, when it was right in front of us.
Anyway, next time you get an error about mismatched quotes, I suggest you carefully check their type. If they look the least bit different, they may not be the right kind of quotes.

Sublime Text 2: How to set up consistent syntax highlighting for Guardfile?

While it is easy enough to set the language for a given (open) file in Sublime Text, I'm wondering if there is any way that I can tell the editor in advance that anything called "Guardfile" should be highlighted like it's Ruby code. Does anyone know how to do this?
The plugins recommended in the comments by Brian both do the job nicely:
ApplySyntax
SyntaxFromFileName
Update:
I couldn't get SyntaxFromFileName to match any of my regex for some reason. On the other hand, DetectSyntax comes with syntax highlight for the Guardfile built in.
Update2:
DetectSyntax has been renamed to ApplySyntax
Putting the following at the top of said file also works
#!/usr/bin/env ruby

Notepad++ like editor with with macrosed text replacements for faster coding

Is there any editor or add-on/plugin which replaces some keywords with prepared snippets in place of written keyword.
For example i'm typing key1 and it's instantly or after a space is replaced with snippet that is assigned to this keyword.
I saw some tutorial from Jeffrey Way long ago, but can't find it now. :s
Thanks ;)
FingerText for Notepad++ pretty much does what you want.
Just use Tab after typing in the keyword you set up for the snippet, and it'll replace it with the snippet.
The Zeus editor has a template feature that does exactly this. A template is a keyword with an associated code snippet and typing in a keyword followed by the space key results in the keyword being replaced by the associated code snippet.
Try installing AutoHotkey version 1.1.19.03 or greater.
One thing it can do is look for sequences of keyboard characters and replace them with other sequences on the fly. As soon as it sees a sequence it will replace it. No activating character is required.
To set up the replacement definitions:
Right click on the Desktop
New
AutoHotkey Script
This will create a template for
your script with the name New AutoHotkey Script.ahk
Edit New AutoHotkey Script.ahk with Notepad++
Put your key snippet lines at
the end, like so:
:*:key1::snippet for key1
:*:key2::snippet this time for key2
Save As My Snippet definitions.ahk
To invoke it: Double click My Snippet definitions.ahk
You can control AutoHotkey by right clicking on its icon on the taskbar.

How do you escape a reserved word in Delphi?

I need to Escape a reserved word to use it as an identifier in Delphi. I thought that was accomplished by using the ampersand "&", but that doesn't seem to be working right. Any other suggestions?
I found the doc page (search for Extended Syntax) on it, and it should be ampersand.
Figured out the problem. The ampersand works for compiling and error insight, but not code completion. Good to know. I had to add an _ suffix to get code completion to work, then change it back afterwords. I should check QC for a bug report.

Resources