A:
The blank space is generated by the border-top in your HTML document. There is no space between the text and the border. The border-top is supposed to be in CSS, but the content of your page is in HTML, so the generated CSS doesn't include it.
If you want to use it, put your text in a div that has a border-top.
something here
.text {
border-top: 1px solid red;
/* Other properties... */
}
Q:
How to get Application from a class within a module
I have tried:
application = objc_get_class("application")
but that just returns the value as string "application"
I have also tried:
objc_get_class("application", true)
but that does not give any output in my console.
How do I access the application object within the module's functions/methods?
A:
You are getting a string because Obj-C methods do not return the result of the method as a value. They return a reference to the return value in the first parameter. Since you're calling the method, not referencing a property, you don't get the actual object.
You can easily make your function return an actual object by passing the result into [NSValue valueWithPointer:](
ex:
-(NSString *)myFunction:(NSString *)result{
return [NSString stringWithFormat:@"%@", [result stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]]];
}
and in your other function:
objc_msgSend(application, @selector(myFunction:), [NSString stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]]);
Q:
Vim: Colored screen help/documentation?
I'm trying to get used to Vim, and my two main difficulties so far have been
searching for "how to do this", "what this does", "what the colors mean"
finding visual basic, eclipse, or any other sort of 01e38acffe
but the error still exists and I have no idea how to get rid of this.
the error is :
"IndexOutOfBoundsException: Index:2, Size:3"
"index1 = 2
index2 = -1
index3 = 1
index4 = 2
index5 = 2
index6 = 2"
Could you help me with this?
Best regards
A:
There is no size 3 in your String array.
The exception is thrown because your String array contains only 2 elements (the first two indexes are 2 and -1).
Name
Synopsis
args[] is a command line parameter that specifies the parameters to the
program. If args is not supplied, it defaults to the directory in which
the program was executed. The command line parameter can include:
a file name that specifies the name of a file that the program will
read
a character constant that specifies a character to be used for the
argument
a string that specifies a string to be used for the argument
a number that specifies an integer to be used for the argument
a function that specifies a function to be used for the argument
a boolean that specifies if the argument should be treated as a
boolean
a real number that specifies the value of the argument
a pointer that specifies a pointer to be used for the argument
A function may take any of these as an argument, and it is the user's
responsibility to provide a valid argument.
A Boolean parameter can be set to a non-zero value to indicate that the
argument should be treated as Boolean.
A function argument can be a pointer to a function or a pointer to a
pointer to a function. If the argument is a function, the user must
define a function to be used.
The user may give any integer as an argument; integer values can be
supplied using the following forms:
integer value
integer value as a character constant
integer value as a string
integer value as a real number
integer value as a function
The integer value may be preceded by the character @ to indicate that
it is a function to be called.
Normally, the user does not need to worry about the size of the integer
argument. The program automatically determines the size and stores it
in an integer variable. The integer argument must
Related links:
Comments