I'm keep getting the EXC_BAD_ACCESS error when I change this code from
label.font = [NSFont systemFontOfSize:(80)];
to
label.font = [NSFont systemFontOfSize:*(((messageSize)))];
The messageSize is set as a double like this.
double *messageSize;
What am I doing wrong?
The asterisk is the symbol for a pointer, that's wrong.
A double is a simple scalar type.
double messageSize;
And you can omit all parentheses.
label.font = [NSFont systemFontOfSize:messageSize];
PS: Actually the expected type of systemFontOfSize
is CGFloat
which is a float
on 32 bit and a double
on 64 bit systems.