wokalski / Distraction-Free-Xcode-plugin

Experience ZEN in Xcode. Distraction free mode, styled after Sublime
MIT License
51 stars 6 forks source link

Incompatible with XVim #30

Open oblitum opened 8 years ago

oblitum commented 8 years ago

Just tried it now that Xcode 7 is supported, it indeed worked, but at the same time disabled any feature of XVim.

wokalski commented 8 years ago

I'm sorry to hear that. I don't use XVim. I just looked at its source and there's a lot of swizzling. Part of it is in classes instances of are not used in ZEN. This is probably the problem.

wokalski commented 8 years ago

I investigated it a little bit and couldn't pinpoint the issue. Only two "swizzled classes" are not used in ZEN - IDEWorkspaceTabController and IDEEditorArea. It doesn't look like there's some critical logic...

oblitum commented 8 years ago

Thanks for the feedback, no need to rush but if you can get it fixed sometime, I would be very glad. The "swizzled classes" thing is gibberish to me, no idea what it means xD

oblitum commented 8 years ago

To add more information, cursor is not visible too when entering distraction free mode, it's visible without XVim.

oblitum commented 8 years ago

XVim cursor is an old-style block instead of a vertical bar.

oblitum commented 8 years ago

Also, since you don't use XVim, you may not be aware what doesn't work. I opened the issue because none of the editing modes and Vim keybindings were working. For example, ESC seems ineffective to enter "normal mode" and walk around with hjkl keys.

wokalski commented 8 years ago

I installed XVim for test's sake. Let's experiment. I think many of vim users would like to see the distraction free mode they are used to.

oblitum commented 8 years ago

Indeed. From searching the web, there seems to be in fact a population of obj-c/swift developers that can't stand xcode and try to code obj-c/swift in vim. Zen-mode with XVim looks much more acceptable =)

wokalski commented 8 years ago

I decided not to work on this issue. It would require quite a few changes and could impact stability of the plugin. I'm leaving this open though if someone else wants to take care of it.

wokalski commented 8 years ago

I will also describe what I found out here.

oblitum commented 8 years ago

=/ OK thanks, I'm willing to work on it if I find any available time.

wokalski commented 8 years ago

More info:

XVim compatibility:

IDEEditorContext also relies heavily on the tab controller to resolve some dependencies. It is currently mocked using ZENIDEEditorContextDependencyManager. This class also contains some mocking of IDEWorkspaceWindowController. This is a mess.

wokalski commented 8 years ago

Oh, and to whoever works on this: just ask if you need more info!

jordwalke commented 8 years ago

I'd love to see this fixed since Distraction Free Mode and Vim kind of go hand in hand!

oblitum commented 8 years ago

I had to choose between the two for now and had to stay with XVim :-(

yam-liu commented 8 years ago

so sad.