On Oct 7, 2014, at 6:29 PM, Daryle Walker <dary...@mac.com> wrote: > I implemented a new window XIB and controller class for my web-browsing > project. It’s for “View Source.” It’s active if the current page’s > WebDataSource object indicates it supports a text representation. The window > just contains a NSTextView-wrapped-in-a-NSScrollView object provided by the > Interface Builder portion of Xcode. The controller has properties for the > source-text, source-URL, and title. These are used during user-interface > Resume; the view-source window never references the originating web-browser > window after creation. The original web-browser window could have its > current-page changed or be closed independently of a view-source window; the > web-browser window also doesn’t track its view-source windows, so you could > (pointlessly) create as many view-source windows for a particular page as you > like. > > 1. Although the text in the window expands vertically as needed, it never > does horizontally. Wrapping always happens when lines are too long, but it > adjusts as the width of the window is changed. How do I get “infinite” space > horizontally? I tried various tweaks in Interface Builder and looked at > various Apple guides, but I can’t turn off the horizontal wrapping. > > 2. I wonder if I should scrap this way of viewing source and use an attached > sheet. This obviously gives up source-viewing as independent. I also have to > add a property to the web-browser window to indicate if source-viewing is > active (so I can Restore that).
[I knew I forgot an Important question.] 3. The text in the view-source window is editable, although I turned that off. (It’s still selectable.) I can cut/copy/paste. Isn’t turning off editing supposed to stop this? — Daryle Walker Mac, Internet, and Video Game Junkie darylew AT mac DOT com _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com