I've had to do some funky things with categories in the past, in at
least one case because some framework had added one but for complex
reasons could not import. So, similar to what Jens said:
The interface description of the category is for the sole purpose of
helping the compiler generate a
I recently saw some code where an object was alloced but there was no init:
Foo *foo = [Foo alloc];
foo.bar = ...
My blood pressure soared! My pulse quickened! I started breathing rapidly!
But then I though - heck, if Foo has NSObject as its super class, gee,
maybe -init isn't really
I've googled til my fingers are black and blue, but no luck finding some
of the older PDF guide documents. I could never express in words how
disappointed I am that Apple discontinued producing readable
documentation - I use to crow about it to all my non-Apple dev friends.
Anyway, does
> How can I update my UI from a background thread?
>
> I have a method that does a LOT of intense processing, it calls a
delegate method in my Window Controller which appends it to a Logging
Scroll View, however nothing shows up in the Scroll View although it
NSLog’s the string ok.
---
Is there a mechanism to do this? Even a gray solid underline that visually
aligns the items works too (background image?)
Serach the documentation for NSUnderlinePatternDot
—Graham
Thanks,
What I had wanted was to place the underline style in the white space
between two items that are
I want to build a table with a left identifier, then a tab stop (well
actually a few), each having some text in it.
What I'd dearly love to do is add a dotted line style underline that
goes from the right position of the left most text then butts up to the
tab stop to its right, up to the
Title pretty much says it - I have a UICollectionView,
hidesBarsWhenVerticallyCompact = true. Rotate to hide the nav bar works
fine.
I can press and drag to scroll, no change. But if I tap on a cell, even
if my code "handles the tap" by implementing the collection view
delegate, the nav bar
I have a UIScrollView scrolled to the bottom of content - so the content
bottom is at the bottom of the view - in a compact environment.
When the view rotates to regular, the contentOffset is too large - so
the bottom of the content appears in the middle of the view.
Without hard coding nav
On 11/6/15 1:17 PM, David Duncan wrote:
On Nov 6, 2015, at 8:04 AM, David Hoerl <dho...@mac.com> wrote:
I know this is an esoteric question.
I enabled 'hidesBarsOnSwipe' in my MMSpreadSheet view controller. This UIView
subclass has 4 UICollectionViews in it - two up top and two
I know this is an esoteric question.
I enabled 'hidesBarsOnSwipe' in my MMSpreadSheet view controller. This
UIView subclass has 4 UICollectionViews in it - two up top and two below.
The top left 'corner' controller does not scroll, and the top right does
not scroll vertically. Out of the box
On 10/7/15 7:27 PM, Jens Alfke wrote:
On Oct 7, 2015, at 4:01 PM, David Hoerl <dho...@mac.com
<mailto:dho...@mac.com>> wrote:
then add a "condensed" attribute:
let fd2 = fd1.fontDescriptorByAddingAttributes[ the magic sauce ]
I haven’t used this API, but from looking
I'd like to do is get a condensed - or better yet - a bold (semi-bold)
condensed version of the "San Francisco" system font.
What I propose to do is get a "starter" font:
let font = UIFont.preferredFontForTextStyle(UIFontTextStyleHeadline)
then get the font descriptor:
let fd1 =
I've been doing all my coding in Swift, and frankly, I couldn't live
without Dash. It imports the Swiftdoc.org docset, and thus you have a
handy reference to essentially all of the Swift.h file.
For instance, you are working with an Array, and want to see all options
to create one, etc. I
Can an iOS app examine some property to determine if its been installed
as a development style app (ie Test Flight, or Xcode, etc), or was
installed via the App Store.
[I support a library where the app is suppose to pass a flag, but
clients are making errors...]
David
);
sandboxReceipt is also the name of the receipt file when running
builds locally.
On Thu, Oct 30, 2014 at 10:38 AM, David Hoerl dho...@mac.com
mailto:dho...@mac.com wrote:
Can an iOS app examine some property to determine if its been
installed as a
development style app (ie Test
I was talking to someone about an idea of giving everyone at a gathering
- say 100 people - iBeacon pendants. An app would have a translation of
everyone there along with their beacon ID, and show the 10 closest
people to any given iOS device..
Would iOS be capabile of detecting 100 or so
On 3/7/14, 10:43 PM, cocoa-dev-requ...@lists.apple.com wrote:
I’ve written a category on NSBezierPath that allows boolean operations on paths (union,
intersection, subtraction) which preserves curved elements throughout the operation and
does not require flattening paths into line segments
Date: Mon, 03 Feb 2014 10:42:47 -0800
From: Matt Neuburg m...@tidbits.com
To: Rick Mann rm...@latencyzero.com
Cc: cocoa-dev@lists.apple.com Dev cocoa-dev@lists.apple.com
Subject: Re: Mismatched viewWillAppear/viewDidDisapper calls possible?
Message-ID:
There have been numerous posts on the internet saying that Apple used
Cassowary as the basis of Autolayout. If so, then why isn't there any
mention of this in the Autolayout document.
Or was this a white room re-write?
Cassowary is open source and as far as I can tell requires no
I believe there are other fora for shooting the breeze.
— F
NOTE: BELOW IS NOT A TECHNICAL POST PER SE - WILL BE LAST ONE FROM ME
I hope this doesn't waste anyone else's time. This is absolutely
technical in the sense that if so, it provides another resource to
better understand the
Becoming increasingly adept at autolayout but currently stumped. What I
am trying to do is design a UICollectionView header that using
constraints is suitable for portrait and landscape.
I have a bunch of views in it, each grouped into a container view. What
I'd like to do is when the view
I have a bunch of views in it, each grouped into a container view. What I'd
like to do is when the view rotates, move the container views around. Currently
this seems impossible because the size of the header (and footer) must be
specified to the Flow Layout before the view is even created,
On 10/4/13 5:09 PM, Steve Christensen wrote:
On Oct 4, 2013, at 1:52 PM, David Hoerl dho...@mac.com wrote:
But its really odd - and I'm thinking about a bug report on this - that the
delegate has to provide the size before the view is even created.
It make sense if you think about it: it's
Look at Valgrind - it works on the Mac now. What you do is have a demo
app or even a GUI that launches, runs, then quits. You enter your app
and args as arguments to valgrind when you run it.
Valgrind monitors every malloc, and when the app/program quits tells you
not only what leaks you
I have a Xcode 4.2 project with a dozen or so nibs. I'm in the process
of assuring that all the resizing is set up properly.
I find that a small number of primary views - the one attached to the
view outlet - have fixed autoresizing masks, and while I can set or
unset the four outter
I just had a lovely time trying to figure out why my UITableView was
snapping back to 0,0 when the keyboard was going away.
In the end I had recently modified my code to use contentInset (and
scrollIndicatorInsets) when the keyboard was visible.
Using lldb with a breakpoint on
I noticed by accident that everything seems to work just fine if I
supply a im...@2x.png in my iOS code, reference as normal [UIImage
imageNamed:@image.png], even if I'm targetting code at a non-retina
iPhone.
So, is this really acceptable? In virtually every image I have, the 1x
image is
Before doing my latest project, I poured over the Model Object
Implementation Guide and the NSManagedObject Class Reference. Both
documents state categorically that NSManagedObjects do NOT automatically
provide KVO notification unless one overrides
+(BOOL)automaticallyNotifiesObserversForKey.
On 5/21/10 9:10 AM, Mike Abdullah wrote:
What does +contextShouldIgnoreUnmodeledPropertyChanges return for your class? I
am wondering if the two are interlinked.
This was an oversight on my part - this app is targeted at 10.5 (and
thus uses the 10.5 SDK.) That Class method is not defined for
I'd like to use Scripting Bridge to find messages in Mail's Inbox that
have attachments with a certain suffix (e.g., txt) and ultimately
retrieve just those.
When I get a reference to Inbox, what I want (in plain English) is ALL
messages that have at least one attachment whose name ends in
This probably takes more time than allocating a new object :-)
My company uses it to scramble memory for invalidated objects that hang
around for a while, to force crashes if accessed (id object addresses
will be bogus).
David
---
void clearIvars(id obj)
{
unsigned int outCount = 0;
Objects:
- NSManagedObject *item - some managaged object
- NSArray *attributes - an array of the item's attributes
Desired Result:
- a possibly smaller array of attribites where [item valueForKey:an
attribute] != nil.
In code, I can simply iterate over the keys, perform the valueForKey,
Having the array of attributes unrolled separately is a little odd. Do you
mean you have an array of attribute names from, say the entity, and you want to
ask a MO for all its non-nil attribute values and get back an array of matching
attribute names for those non-nil values?
- Ben
I am getting consistent crashes when a newly created
NSCollectionViewItem has a view with an animating spinner (the animation
property is enabled through bindings that kick in immediately on
creation). It happens on 10.5 as well as 10.6. [ rdar://7727603 bug has
demo project included].
Log
[This is for the archives - to finish off an unresolved thread]
[Keywords programatically show display NSSegmentedCell
NSSegmentedControl menu performClick ]
The way to have the segmented cell open a menu is to do it in two steps:
[segmentedControl setSelectedSegment:0]; // set the desired
I had an issue (since resolved) where an object set a property to nil
directly, without providing KVO notification. Later, the app crashed:
Running with debug and Zombies enabled got me here:
-[NSKeyValueObservance retain]: message sent to deallocated instance
In the end, I discovered that
The solution is (using the original OpenGLScreenCapture project code)
to modify this statement in FrameReader.m:
glCopyTexSubImage2D(GL_TEXTURE_RECTANGLE_ARB, 0, 0, 0, 0, 0, mWidth, mHeight);
to
glCopyTexSubImage2D(GL_TEXTURE_RECTANGLE_ARB, 0, 0, 0, 100, 50,
mWidth+100, mHeight+50);
where
Look at the EDMessage class:
http://www.mulle-kybernetik.com/software/EDFrameworks/ . You need its
sibling class EDCommon too. With that Cocoa framework, you can send
email through a SMTP access point using various types of security -
it works with .mac and google too.
I know these work as I
Create a NSTextFieldCell and customize it. Create a NSMatrix using
the prototype init version, and display it. All the custom
formatting is gone - all cells are vanilla NSTextFieldCells.
Loop through the matrix, and set each cell to a copy of the cell I
used as a prototype, using the
The libxls open source project on sourceforge.net allows you to read
and parse .xls files. This library works under OSX - I know, I'm one
of the developers :-)
David
___
Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
Please do not post admin
[for the archives - old thread]
This is a brute force mechanism to save the expanded NSOutlineView
items prior to changing a Managed Object context and then restoring
them after the modification.
- (id)expandedState
{
NSMutableArray *state = [NSMutableArray array];
NSInteger count =
Using 10.5.6, my inspection panel has a NSTreeController that has two
bindings - ContentSet and Parameter (the first to a set of objects,
the latter to the manageObjectContext). Using NSLog's I have verified
the bindings are correct.
The problem comes when I set Uses Lazy Evaluation (ala
[following up to a Jan 08 thread]
is it possible to modify the width of the NSTextField representing
a Number in a NSPredicateEditorRowTemplate ?
Yes, but not yet in Interface Builder. To do so programatically, get
the row template, get the text field as the last member of the row
Hello.
Are there any abstractions in Cocoa to open and handle Exel and
PowerPoint files?
Thank you.
Timofey.
Well, there are ways to read and write excel files - look on
sourceforge for libxls and xlslib (the first library can read an .xls
file, and xlslib can write one). I contribute to
Thanks to those who have posted on this, and suggested workarounds.
However, in a simple non-threaded app, this call should work, no? And
perhaps the 0 time timer would also suffer the same fate.
The project has a checkbox so the user can enable the CFWakeup.
To convince myself this was not
I have a few hundred tasks to handle, and am using NSRunLoop's
performSelector to get the scheduled:
-(void)nextTask:(SEL)sel
{
[[NSRunLoop mainRunLoop] performSelector:sel target:self argument:nil order:0
modes:[NSArray arrayWithObject:NSDefaultRunLoopMode]];
CFRunLoopRef crf
Cocoa provides the NSMailDelivery class to support sending email
from a Cocoa application. Is there an analog for receiving email?
what is the best way for the application to receive emails?
Look at EDMessage - for historical information look at this page:
I recently tried to update a page on cocoadev.com, but the changes
didn't take. I looked at the Recent Changes page and the latest
is October 23rd. There is no obvious contact - I did send a email to
Panic but have not heard back.
Anyone know what's going on?
David
I'm using a CATextLayer to display some text which the user can change
the font size of. When the user changes the font size, I still want my
text to be centered, both vertically and horizontally.
As far as I know you can only set the the CATextLayers alignmentMode
to kCAAlignmentCenter to
The NSPathControl.h file says that when in Popup mode, the control
will send a action message. However, I cannot get it to work. I've
tried using no types, and a type of public.folder.
Is this a known problem?
I was able to create a hack work-around: use the NSPathControl
delegate method -
dream cat7 wrote:
I agree that to be able to use that syntax is highly desirable, and
indeed missing from all the cocoa libraries that I have looked at. One
way would be a category addition to NSString class, which would call
the perl -pe 's/\b(.*?)/\u\L$1/g' for you and return the
There is an open source option in the works. Look at EDMessage on:
http://www.mulle-kybernetik.com/software/EDFrameworks/
You will see three open source frameworks. EDMessage provides
equivalent if not more functionality than NSMailDelivery by directly
interacting with a SMTP server.
[For the archives, or anyone else interested in this topic]
Ken Thomases provided a shorter version, by having the NSData
instance write the file. Jean-Daniel Dupas suggested using
CFPropertyListWriteToStream to bypass the intermediate NSData object
(a speed and memory footprint improvement)
I'm using [NSDictionary writeToFile:...] to save a fairly large
dictionary as a text plist file. I found a quick and dirty hack to
convert it into a binary formatted file:
strcpy(command, /usr/bin/plutil -convert binary1 );
strcat(command, fileName);
ret = system(command);
Yeah, I
I never did get a pointers to code to convert a NSDictionary to a
binary formatted plist, but did get pointers to look at
NSPropertyListSerialization - something I had already (mis)read a few
times.
The description for the dataFromPropertyList class method seems
confusing if you don't
I have the same need and am trying to resurrect EDMessage (whose
project does not now even compile).
Just a quick note - this capability is of great value when your code
is running on some server inside a firewall, and you want to get
periodic status messages (and that server itself does not
Position: Media Application Developer - MacOS Expert
Location: Northern, NJ
Duration: Contract 2 3 months with possible extension
To apply for this position please forward your resume in WORD format
referring the position the position title above to:
[EMAIL PROTECTED]
Due
I cannot find nothing in the Xcode user documentation, the Core Data
documentation, nor on this list that explain what the Indexed
checkbox in Xcode 3's Attribute panel is for.
A link or short explanation would be helpful. Thanks!
David
___
58 matches
Mail list logo