Skip to content

Commit cea4fae

Browse files
committed
Various tweaks and fixes.
1 parent ac13b9f commit cea4fae

File tree

5 files changed

+32
-100
lines changed

5 files changed

+32
-100
lines changed

README.md

Lines changed: 22 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,34 @@
1-
# SCXcodeMiniMap
1+
# SCXcodeMinimap v2.0
2+
SCXcodeMiniMap is a Xcode plugin that adds a source editor Minimap to Xcode.
23

3-
SCXcodeMiniMap is a plugin that adds a source editor MiniMap to Xcode.
4+
Version 2.0 has been rewritten from the ground up to address performance issues (delays on large source files - 1000+ lines) and for creating a better base to build upon. As such, the following new features are now supported:
45

5-
![SCXcodeMiniMap](https://dl.dropboxusercontent.com/u/12748201/SCXcodeMiniMap/SCXcodeMiniMapv1.3.png)
6+
#### New Features
7+
- Faster syntax highlighting
8+
- Shows code foldings
9+
- Comment and preprocessor directive highlighting
10+
- Breakpoint highlighting
11+
- All highlighting options are also available for the main Xcode editor
12+
- Custom themes
13+
- All options are accessible from the View/Minimap menu item
614

7-
## Features
8-
- It works with an unlimited number of opened editors, including the assistant and version editors
9-
- The minimap and its selection view scroll seamlessly with the editor and provide a nice way of figuring out the current position in the document
10-
- Full syntax highlighting
11-
- It blends with the currently selected theme
12-
- View menu item for showing/hiding it (Ctrl+Shift+M)
13-
- Size configurable via the kDefaultZoomLevel parameter (defaults to 10% out of the editor's size)
15+
#### Screenshots
16+
Without editor highlighting | With editor highlighting
17+
:--------------------------:|:--------------------------:
18+
![](https://dl.dropboxusercontent.com/u/12748201/SCXcodeMiniMap/v2.0/SCXcodeMinimap%20v2.0-01.png) | ![](https://dl.dropboxusercontent.com/u/12748201/SCXcodeMiniMap/v2.0/SCXcodeMinimap%20v2.0-03.png) |
19+
![](https://dl.dropboxusercontent.com/u/12748201/SCXcodeMiniMap/v2.0/SCXcodeMinimap%20v2.0-02.png) | ![](https://dl.dropboxusercontent.com/u/12748201/SCXcodeMiniMap/v2.0/SCXcodeMinimap%20v2.0-04.png) |
1420

15-
## Installation
16-
- Build the project and restart Xcode or
21+
#### Installation
22+
- Through [Alcatraz](https://github.com/supermarin/Alcatraz)
23+
24+
- Download the sources, build the project and restart Xcode
1725

1826
- Download SCXcodeMinimap.xcplugin.zip from the releases tab, unzip and move it to the Xcode plugins folder ~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/SCXcodeMinimap.xcplugin
1927

2028
- If you encounter any issues you can uninstall it by removing the ~/Library/Application Support/Developer/Shared/Xcode/Plug-ins/SCXcodeMinimap.xcplugin folder
2129

22-
## License
30+
#### License
2331
SCXcodeMiniMap is released under the GNU GENERAL PUBLIC LICENSE (see the LICENSE file)
2432

25-
## Contact
33+
#### Contact
2634
Any suggestions or improvements are more than welcome. Feel free to contact me at [stefan.ceriu@yahoo.com](mailto:stefan.ceriu@yahoo.com) or [@stefanceriu](https://twitter.com/stefanceriu).

SCXcodeMinimap.xcodeproj/project.pbxproj

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
objects = {
88

99
/* Begin PBXBuildFile section */
10-
18143CC41A98A83700BD8DD8 /* DVTTextDocumentLocation+SCXcodeMinimap.m in Sources */ = {isa = PBXBuildFile; fileRef = 18143CC31A98A83700BD8DD8 /* DVTTextDocumentLocation+SCXcodeMinimap.m */; };
1110
184C11861A740F97002A7C65 /* SCXcodeMinimapSelectionView.m in Sources */ = {isa = PBXBuildFile; fileRef = 184C11821A740F97002A7C65 /* SCXcodeMinimapSelectionView.m */; };
1211
184C11871A740F97002A7C65 /* SCXcodeMinimapView.m in Sources */ = {isa = PBXBuildFile; fileRef = 184C11841A740F97002A7C65 /* SCXcodeMinimapView.m */; };
1312
184C118F1A741136002A7C65 /* DVTFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 184C118E1A741136002A7C65 /* DVTFoundation.framework */; };
@@ -26,8 +25,6 @@
2625
/* Begin PBXFileReference section */
2726
180F0C651A98AE1500E97254 /* DVTAnnotationManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DVTAnnotationManager.h; sourceTree = "<group>"; };
2827
1812C3911A77A7CF00E2CFB3 /* IDESourceCodeDocument.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = IDESourceCodeDocument.h; sourceTree = "<group>"; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; };
29-
18143CC21A98A83700BD8DD8 /* DVTTextDocumentLocation+SCXcodeMinimap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "DVTTextDocumentLocation+SCXcodeMinimap.h"; sourceTree = "<group>"; };
30-
18143CC31A98A83700BD8DD8 /* DVTTextDocumentLocation+SCXcodeMinimap.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "DVTTextDocumentLocation+SCXcodeMinimap.m"; sourceTree = "<group>"; };
3128
18269AD51A8F2F4300953B3D /* DVTFoldingManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DVTFoldingManager.h; sourceTree = "<group>"; };
3229
184407641A8F7B1900C530CF /* DVTTextDocumentLocation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DVTTextDocumentLocation.h; sourceTree = "<group>"; };
3330
184407651A8F7B3E00C530CF /* DVTDocumentLocation.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DVTDocumentLocation.h; sourceTree = "<group>"; };
@@ -186,8 +183,6 @@
186183
184C11841A740F97002A7C65 /* SCXcodeMinimapView.m */,
187184
184C11811A740F97002A7C65 /* SCXcodeMinimapSelectionView.h */,
188185
184C11821A740F97002A7C65 /* SCXcodeMinimapSelectionView.m */,
189-
18143CC21A98A83700BD8DD8 /* DVTTextDocumentLocation+SCXcodeMinimap.h */,
190-
18143CC31A98A83700BD8DD8 /* DVTTextDocumentLocation+SCXcodeMinimap.m */,
191186
188FCC881A98B57A0026F529 /* DBGBreakpointAnnotationProvider+SCXcodeMinimap.h */,
192187
188FCC891A98B57A0026F529 /* DBGBreakpointAnnotationProvider+SCXcodeMinimap.m */,
193188
18FE09BC1707639E00118FEB /* Supporting Files */,
@@ -268,7 +263,6 @@
268263
buildActionMask = 2147483647;
269264
files = (
270265
188FCC8A1A98B57A0026F529 /* DBGBreakpointAnnotationProvider+SCXcodeMinimap.m in Sources */,
271-
18143CC41A98A83700BD8DD8 /* DVTTextDocumentLocation+SCXcodeMinimap.m in Sources */,
272266
18FE09C9170764E400118FEB /* SCXcodeMinimap.m in Sources */,
273267
184C11861A740F97002A7C65 /* SCXcodeMinimapSelectionView.m in Sources */,
274268
184C11871A740F97002A7C65 /* SCXcodeMinimapView.m in Sources */,

SCXcodeMinimap/DVTTextDocumentLocation+SCXcodeMinimap.h

Lines changed: 0 additions & 13 deletions
This file was deleted.

SCXcodeMinimap/DVTTextDocumentLocation+SCXcodeMinimap.m

Lines changed: 0 additions & 61 deletions
This file was deleted.

SCXcodeMinimap/SCXcodeMinimapView.m

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -214,11 +214,11 @@ - (void)setVisible:(BOOL)visible
214214
if(visible) {
215215
[self updateOffset];
216216
[self.textView.layoutManager setDelegate:self];
217-
218-
BOOL editorHighlightingEnabled = [[[NSUserDefaults standardUserDefaults] objectForKey:SCXcodeMinimapShouldHighlightEditorKey] boolValue];
219-
if(editorHighlightingEnabled) {
220-
[self.editorTextView.layoutManager setDelegate:self];
221-
}
217+
}
218+
219+
BOOL editorHighlightingEnabled = [[[NSUserDefaults standardUserDefaults] objectForKey:SCXcodeMinimapShouldHighlightEditorKey] boolValue];
220+
if(editorHighlightingEnabled) {
221+
[self.editorTextView.layoutManager setDelegate:self];
222222
}
223223
}
224224

@@ -230,7 +230,11 @@ - (NSDictionary *)layoutManager:(NSLayoutManager *)layoutManager
230230
atCharacterIndex:(NSUInteger)charIndex
231231
effectiveRange:(NSRangePointer)effectiveCharRange
232232
{
233-
if(!toScreen || self.hidden) {
233+
if(!toScreen) {
234+
return nil;
235+
}
236+
237+
if(self.hidden && [layoutManager isEqual:self.textView.layoutManager]) {
234238
return nil;
235239
}
236240

0 commit comments

Comments
 (0)