Hello,
I have an application in which the user can continuously zoom and pan a canvas
(kind of like Google Maps). On the canvas, a user can have multiple text
items. Each text item is a Core Animation layer, and the text is drawn using
NSLayoutManager's drawGlyphsForGlyphRange method.
When t
Hello,
I have setup an FSEventStream so that I can monitor a directory for file
changes. If the root directory that is being watched is moved/renamed, I want
to be able to keep monitoring the directory. I am able to get the new path of
the root directory, however I am unsure of how to monitor
> Because it was mono-Font text, I resorted to scaling the font
> instead.
Actually I did try scaling the font instead of the text view, but I'm unable to
get the text to scale linearly as our application should be able to handle most
fonts.
> I never went back to view scaling, but I wonder
> i
> I hope that there are no issues scaling an NSTextView that is layer-backed
> (either using NSView's scaleUnitSquareToSize method, or the bounds
> manipulation approach that TextEdit uses).
Unfortunately, there seems to be issues with scaling an NSTextView in a
layer-backed hierarchy as well -
Thanks Kyle, that's quite helpful.
We were initially hesitant to add the NSTextView directly to the layer-hosted
view, however the following thread consoled us a little, especially since we
were able to get geometry working correctly:
http://www.mail-archive.com/cocoa-dev@lists.apple.com/msg2195
>> Also, you should disable screen font substitution via -[NSLayoutManager
>> setUsesScreenFont:NO].
>>
>> This is the main source of glyph advancement differences you're seeing.
>
> Thanks Aki, indeed this has removed the small horizontal offset that was
> there.
>
> I am however unable to fi
On 2011-05-25, at 3:41 PM, Douglas Davidson wrote:
>
> On May 25, 2011, at 2:37 PM, Ajay Sabhaney wrote:
>
>> - Instead of trying to scale text linearly, use a transformation to scale
>> the NSTextView and image representation appropriately. While this is easy
>>
> Also, you should disable screen font substitution via -[NSLayoutManager
> setUsesScreenFont:NO].
>
> This is the main source of glyph advancement differences you're seeing.
Thanks Aki, indeed this has removed the small horizontal offset that was there.
I am however unable to figure out where
Hello list,
I am working on an application in which a user may insert, resize, and edit
text boxes in a workspace. We anticipate that a single user will have many
(possibly hundreds) of text items in a workspace. The user is also able to pan
and zoom in/out of a workspace. Because of the per
Hello list,
I am creating a window with a borderless style mask applied. Even though
content is drawn, the shadow of the window is much less intense than normal
windows. I've tried the setHasShadow: setter and using the invalidateShadow
method, however neither work. I've found one similar po
Hello list,
I have a Core Data based application with a simple data model. There is an
entity 'ItemContainer' which has a to-many relationship with the entity 'Item'.
An item model entity corresponds to a Core Animation layer, so when a new Item
managed object is added to the ItemContainer ma
> Try using a technique similar to the Department/Employees Core Data tutorial
> in the documentation. That is, you can have a singleton object of a new
> entity, (say, ItemSet), which has a to-many relationship "items" to all of
> the Item objects. Bind the NSArrayController's content to the "i
> I'm guessing, but you seem to have a managed object with a to-many
> relationship, and you want to be notified whenever anything is added to or
> removed from that relationship property.
I think I understand the confusion now. I do not actually have a managed
object that has a to-many relati
> I'm guessing, but you seem to have a managed object with a to-many
> relationship, and you want to be notified whenever anything is added to or
> removed from that relationship property. So, observe that property of the
> managed object, and you're done.
>
> If there's something more complica
On 2010-08-22, at 11:54 PM, Jerry Krinock wrote:
>
>> it was *necessary*
>
> [emphasis added]
>
>> for me to receive a KVO notification when either a new item was added to the
>> array controller, or removed from the array controller
>
> I'd say that this assumption is the problem. What you
Hello all,
In my Core Data based application, I have an NSArrayController, and it was
necessary for me to receive a KVO notification when either a new item was added
to the array controller, or removed from the array controller. By looking in
to some forums, I found out that I cannot do this b
yle Sluder wrote:
> On Thu, Jun 17, 2010 at 5:09 PM, Ajay Sabhaney
> wrote:
>> -The initializer initWithLayer: of my subclass of CALayer,
>> MRWorkspaceItemLayer is being invoked, even though I never explicitly invoke
>> this
>
> The documentation for -[CALayer initWi
On 2010-06-17, at 5:19 PM, David Duncan wrote:
> On Jun 17, 2010, at 2:04 AM, Ajay Sabhaney wrote:
>
>> ab.borderColor=CGColorCreateGenericRGB(1.0f,1.0f,1.0f,1.0f);
>
> Be aware that you are actually leaking a color here. Core Animation retains
> all CF-type data that i
Hello list,
In my application, there are several CALayers (actually subclasses of CALayers)
that are sublayers of my root layer. The user can then drag these layers
around and select them, etc. Dragging works fine.
When a user selects/deselects one of the layers, the following code snippet is
19 matches
Mail list logo