Commit Graph

2131 Commits

Author SHA1 Message Date
Allan Odgaard
bef21962c8 Changing font (Show Fonts) would fail when current font was ‘nil’ 2014-07-06 22:16:14 +02:00
Allan Odgaard
5af1ec23ca Enable ligatures
If you are using the Mensch font then you need to update to version 2 to avoid problems with the ligature for ‘fi’: http://robey.lag.net/2012/08/22/mensch-2.html
2014-07-06 14:50:11 +02:00
Ronald Wampler
cc64b1e24f Add search field to Bundle preference pane 2014-07-06 11:34:34 +02:00
Ronald Wampler
8f50838b25 Use "System Small" font in VariablesPreference table
Since variable strings can be very long and we reduced the font size in the bundle table, let's be consistent and use a smaller font size here too.
2014-07-06 11:34:33 +02:00
Ronald Wampler
a2690f9418 Save VariablesPreferences.xib with Xcode 5.1.1 (5B1008) 2014-07-06 11:34:33 +02:00
Ronald Wampler
9812748a07 Use "System Small" fonts in BundlePreference table
By using a smaller font size in the bundle table we can show more of the bundle description. Also, it minimizes the amount of resizing of the pane we have to do to see the entire description string for most of the bundles.
2014-07-06 11:34:33 +02:00
Ronald Wampler
360443682d Save BundlePreferences.xib with Xcode 5.1.1 (5B1008) 2014-07-06 11:34:33 +02:00
Allan Odgaard
f370408910 File browser actions were disabled for broken symbolic links
This made it impossible to move a broken symbolic link to trash.
2014-07-05 21:33:29 +02:00
Allan Odgaard
2c8a020d39 Implement selectNext/PreviousTab in FindWindowController 2014-07-05 21:33:29 +02:00
Allan Odgaard
42a64270bc Remove undesired whitespace 2014-07-05 21:33:29 +02:00
Boris Dušek
eea001f5d5 Fix build error on clear rebuild
When rebuilding textmate from scratch:

git clean -xffd; git reset --hard HEAD; rm -rf ~/build/TextMate/; ./configure; ninja

This error appears:

Frameworks/OakAppKit/src/OakTabBarView.mm:7:9: fatal error: 'OakAppKit/OakFileIconImage.h' file not found

After one issues "ninja" again, textmate continues building fine.

I guess this might be because perhaps OakAppKit's headers are being copied
to the build include directory (~/build/TextMate/include) in parallel when
building OakTabBarView.mm. No matter what actually is the case, this patch
fixes building during clean build.
2014-06-29 21:40:33 +02:00
Boris Dušek
900ee1f523 Use NSAccessibilitySharedFocusElementsAttribute in OakChooser
This new 10.10 API allows one to mark, for some UI element, a set of UI
elements to track selection. VoiceOver (and other accessibility clients)
will then track and announce selection (cursor) changes not only in the
currently focused element, but also for all elements contained in its
"shared focus elements" array. This is a perfect fit for search field
with a table of results. In fact it is used for new 10.10 Spotlight -
its search field's shared focus element is the table containing the results.

As NSAccessibilitySharedFocusElementsAttribute is available only in the 10.10 SDK,
so make a way to use its value with previous SDKs (with which TextMate
is currently compiled).

We also retain the kind-of-hacky solution for pre-10.10 OSes introduced in
and instead use NSAccessibilitySharedFocusElementsAttribute.

This code was tested in all 6 fields of a 3×2 matrix:
* compiled with 10.8, 10.9 and 10.10 SDK
* run on 10.9 and 10.10 (DP2)

For user, this means more standard behavior (says the same "completion selected"
thing as with Spotlight) and a bit more correctness (no extra space
before beginning / after end of search field on braille display).

For developer, this means once we stop supporting 10.9, we will be ready to
drop a lot of code which, while serving us well to make the choosers more
user friendly on pre-10.10, will no longer be needed.
2014-06-29 11:01:58 +02:00
Allan Odgaard
a76b6eae9c Respond to next/previous tab actions in file/favorites chooser
This makes it possible to use ⌘{ and ⌘} to move between the source lists, which is consistent with other windows with multiple sources (like the Preferences and About windows).

Closes #1236.
2014-06-28 18:22:02 +02:00
Adam Strzelecki
59a699c078 Tune tab label inset shadow
Now it matches more way other OSX elements are inset both on Retina and
non-Retina displays.
2014-06-28 18:02:00 +02:00
Adam Strzelecki
56cfc1a3e0 Reworked OakTabBarView layout plist
Now it supports properly Retina using Cocoa rounded corner rendering instead
pixel patches. All colors are now references by name.
2014-06-28 18:02:00 +02:00
Adam Strzelecki
2ef711ad97 Define color names for OakTabBarView
This lets layout file refer to color names instead hardcoding color hex values.

Also colors referenced by name can return different values depending on OSX
version, which will in future solve problems with OSX 10.10 Yosemite L&F.
2014-06-28 17:59:27 +02:00
Adam Strzelecki
53943e4409 Extend layer_t with cornerRadius & borderColor
This allows drawing rounded layers with border in resolution independent
manner. Also it reduces number of layers needed to certain UI elements.
2014-06-28 17:56:50 +02:00
Boris Dušek
72bb6e6eb6 Fix enum/int conversion error with 10.10 SDK
10.10 SDK makes NSLineBreakMode into a proper NS_ENUM enum (in 10.9 SDK it was
a plain typedef for NSUInteger with some integer NSLineBreak* values
conveniently available for it in an anonymous enum).

Nevertheless, attr_string code should have always used NSLineBreakMode instead
of NSUInteger (unless I am missing something like values in style::line_break::mode
that do not correspond to the enum), so this commit makes it so and
thus also fixes building with 10.10 SDK.
2014-06-28 17:54:16 +02:00
Allan Odgaard
2427464f60 Disable tar’s support for extended attributes and resource forks
A problem has been reported where tar will freeze while extracting the default bundles archive to a networked Application Support folder.

From the bug report (Michael Kuron):

File servers tested: SMB on OS X 10.9.3, AFP on OS X 10.9.3, AFP on OS X 10.6.8, SMB on Windows 2008 R2.

Multiple machines tested.

Using ‘gnutar’ from MacPorts does not show the problem.

Setting ‘COPYFILE_DISABLE=1’ before running tar does not show the problem (the workaround used in this commit).
2014-06-28 17:42:23 +02:00
Allan Odgaard
e78764a89e Let threaded syntax highlight parsing for ng::buffer_t be opt-in 2014-06-28 17:42:23 +02:00
Allan Odgaard
0ae6782d80 Remove support for custom views in OakControl 2014-06-28 17:42:23 +02:00
Allan Odgaard
c1552d56bc Include some context in error message 2014-06-28 17:42:23 +02:00
Allan Odgaard
7675aeb4ec Changing case would truncate the result if it grew in size 2014-06-28 17:42:22 +02:00
Allan Odgaard
6be2935518 Type/format arguments for SecItemImport were swapped
Also collect proper error code incase the function fails.
2014-06-28 17:42:22 +02:00
Allan Odgaard
3a0adfb6bf Collect proper error code if SecItemCopyMatching fails 2014-06-28 17:42:22 +02:00
Ronald Wampler
6dd2dc1c5e Use document icons in overflow menu 2014-06-28 17:42:22 +02:00
Ronald Wampler
2dbd0d601f OakTabBarView datasource now sends the unabbreviated path 2014-06-28 17:42:22 +02:00
Ronald Wampler
c5d801cca9 Adjust click target for tab overflow button 2014-06-28 17:42:22 +02:00
Ronald Wampler
28e58bf4a4 Add effect when the tab overflow button is clicked 2014-06-28 17:42:21 +02:00
Ronald Wampler
673f5a4b73 Adjust appearance of the TabOverflow image 2014-06-28 17:42:21 +02:00
Ronald Wampler
0b3cf27cfd Add Retina asset for TabOverflow 2014-06-28 17:42:21 +02:00
Allan Odgaard
8782e2aa81 Fix bug with PATH variable containing trailing zero byte 2014-05-18 23:14:07 +07:00
Allan Odgaard
539dee1486 Gutter view colors would be leaked when reloading themes 2014-05-17 13:21:53 +07:00
Allan Odgaard
b45ad48c00 Add attr.project.vagrant and attr.project.jekyll scopes
The latter is added when we detect a ‘_config.yml’ file in the project. This might cause false positives, but I am not aware of a better way to detect jekyll projects.
2014-05-17 13:21:53 +07:00
Allan Odgaard
4e5a7fdfe6 Delete clipboard history when seeing NSFileReadCorruptFileError 2014-05-17 13:21:53 +07:00
Allan Odgaard
49f746e795 Update saved per-window project state when terminating TextMate 2014-05-17 13:21:53 +07:00
Allan Odgaard
2b74e76a2f Disable concurrent buffer parsing when not on main thread
The problem is that we can only return to the proper thread/queue when we know what that thread/queue is. Additionally, when running tests, we are calling from a concurrent queue, so even knowing the queue, we cannot safely update the buffer with the new scopes, as only a serial queue can give us exclusive access.
2014-05-16 22:11:29 +07:00
Allan Odgaard
d7dba7cd7a Drop the oak::server_t abstraction for buffer parser 2014-05-16 22:11:29 +07:00
Allan Odgaard
42888110fb Add ‘saveOnBlur’ as a .tm_properties option
This makes it easier to enable auto-saving when TextMate loses focus and unlike using a command for this, files that cannot be saved will be silently skipped (as the user is leaving TextMate, so we should not throw up dialogs).
2014-05-16 22:11:28 +07:00
Allan Odgaard
8919ad3461 Remove duplicate code 2014-05-16 22:11:28 +07:00
Allan Odgaard
e81286b0cd Remove unused include 2014-05-16 22:11:28 +07:00
Allan Odgaard
0286a10cbc Remove unnecessary code 2014-05-16 22:11:28 +07:00
Allan Odgaard
a5dd8cc2d7 Save white I-beam cursor image with LZW compression 2014-05-16 22:11:27 +07:00
Allan Odgaard
41e4ed2cc3 Save PDF images with Preview’s “Reduce File Size” quartz filter
This reduced the file size with more than 90%.

Since the PDF files are mapped into TextMate’s address space, it results in a reduction of memory usage.
2014-05-16 22:11:27 +07:00
Allan Odgaard
af3f4aaa33 Check result of most CF/CT ‘Create’ functions 2014-05-15 13:17:30 +07:00
Allan Odgaard
b8804d1164 Fix three memory leaks
One was per launch, one was per key event, and one was per (unique) line drawn.
2014-05-15 13:17:29 +07:00
Allan Odgaard
55b5b7a3dc Use path::escape when creating TM_SELECTED_FILES
In addition to being redundant, now that we have a global escape function, the custom shell escaping code had a bug when the path contained more than one apostrophe.
2014-04-30 12:09:47 +07:00
Ronald Wampler
4c973385a8 Indent menu items in tabSizeMenu
This allow the check mark to be properly spaced with respect to its item.
2014-04-30 12:09:47 +07:00
Ronald Wampler
fc5dcf4020 Prefer NULL to nop: in most cases
This change was prompted by the appearance of the `tabSizePopUp` button in the status bar. After dismissing the menu, the title would be disabled.

To ensure we do not have similar issues elsewhere, let's prefer the use of `NULL` to `nop:` when assigning the action for menu items unless we are sure that the menu item should always be disabled (e.g., the item is used as a label).
2014-04-30 12:09:47 +07:00
Ronald Wampler
d9f4fae635 Enable "Open Files" search option in Find window
This seems to have been overlooked since most of logic was already implemented.

There is one known issue that exists when restoring sessions. Namely, after restoring a session only those documents (tabs), which have been actively "viewed" are considered "opened".
2014-04-30 12:09:46 +07:00