Welcome to NeoOffice developer notes and announcements
NeoOffice
Developer notes and announcements
 
 

This website is an archive and is no longer active
NeoOffice announcements have moved to the NeoOffice News website


Support
· Forums
· NeoOffice Support
· NeoWiki


Announcements
· Twitter @NeoOffice


Downloads
· Download NeoOffice


  
NeoOffice :: View topic - recognize system key bindings
recognize system key bindings
 
   NeoOffice Forum Index -> NeoOffice Development
View previous topic :: View next topic  
Author Message
susfour
Blue Pill


Joined: Oct 13, 2004
Posts: 3

PostPosted: Wed Oct 13, 2004 10:08 am    Post subject: recognize system key bindings

Could someone comment (or point me to the thread I couldn't find) on the possibility of neo/j using the user's ~/Library/KeyBindings?
Back to top
OPENSTEP
The One
The One


Joined: May 25, 2003
Posts: 4752
Location: Santa Barbara, CA

PostPosted: Thu Oct 14, 2004 1:16 am    Post subject:

Oof. Chances are the user keybindings from the regular Keyboard preferences in a 10.3 system won't work and probably won't for some time. OOo/Neo have their own keyboard shortcut mechanisms for mapping menus to key combos internally and do not use the standard Mac menu commands that are required (I think) for the app-specific or global keyboard shortcuts to work properly. The Mac Keyboard preferences shortcuts are tied to native Mac menu commands from my understanding.

ed
Back to top
susfour
Blue Pill


Joined: Oct 13, 2004
Posts: 3

PostPosted: Thu Oct 14, 2004 5:52 am    Post subject:

Ed, I'm thinking more of keybindings that are not associated with menus. I definitely don't understand how they all tie together, but I want to clarify what I'm looking for in neooffice:

In my ~/Library/KeyBindings/DefaultKeyBinding.dict, I have (among other things):

Code:

<dict>
        <key>^a</key>
        <string>moveToBeginningOfLine:</string>
        <key>^e</key>
        <string>moveToEndOfLine:</string>
</dict>


So that in almost all apps, I can Ctrl-a and the cursor moves to the beginning fo that line and Ctrl-e moves the cursor to the end of that line. Having this functionality in my text editors, web browsers, and any window in the OS, then not having the work in neo/j is very frustrating -- it's one of the key places I need it.
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Thu Oct 14, 2004 7:21 am    Post subject:

The reason that this does not work is that Java 1.3.1 (which handles all of Neo/J's key mapping) seems to ignore any custom keyboard mappings set in ~/Library/KeyBinding.

Maybe Java 1.4.x can handle it but, unfortunately, upgrading our code to Java 1.4.x is a long way off.

Patrick
Back to top
sardisson
Town Crier
Town Crier


Joined: Feb 01, 2004
Posts: 4588

PostPosted: Thu Oct 14, 2004 1:57 pm    Post subject:

OPENSTEP wrote:
Oof. Chances are the user keybindings from the regular Keyboard preferences in a 10.3 system won't work and probably won't for some time. OOo/Neo have their own keyboard shortcut mechanisms for mapping menus to key combos internally and do not use the standard Mac menu commands that are required (I think) for the app-specific or global keyboard shortcuts to work properly. The Mac Keyboard preferences shortcuts are tied to native Mac menu commands from my understanding.

ed


Ed, the wonderful thing about your native menu work is that the 10.3 Keyboard Shortcuts options in Keyboard & Mouse system prefs do work with the Aqua menus! (The keyboard prefs shortcuts seem to be tied to native menu item names rather than commands Smile) At least they work for things that don't have OOo shortcuts; I haven't tried setting a new shortcut in 10.3 for something that already has one in OOo/NeoJ. So thanks again for all of that code!

The keybindings the thread is really asking about are new to me, so I've learned something today Smile

Smokey
Back to top
JKT
The Anomaly
(earlier version)


Joined: Sep 18, 2003
Posts: 434
Location: London, UK

PostPosted: Fri Oct 15, 2004 5:05 am    Post subject:

sardisson wrote:
The keybindings the thread is really asking about are new to me, so I've learned something today Smile

Smokey

As a FYI, all text based Cocoa apps support the control-a/control-e keybindings automatically (I think they are based on emacs or vi or something and are inherited from the NeXT days). Other examples are ctrl-d deletes forward, ctrl-h deletes backward; ctrl-right or left arrow jumps to the end/beginning of the line (not the sentence, like a/e); ctrl-n/ctrl-p jumps back/forward one line.

_________________
PBG4, 1.5GHz, SuperDrive, 1GB RAM, 128MB VRAM, 5400rpm 80GB HD, MacOS X 10.4.5

Please visit The Land Gallery at http://www.thelandgallery.com for nature-inspired British Fine Art
Back to top
susfour
Blue Pill


Joined: Oct 13, 2004
Posts: 3

PostPosted: Fri Oct 15, 2004 1:53 pm    Post subject:

Quote:
As a FYI, all text based Cocoa apps support the control-a/control-e keybindings automatically (I think they are based on emacs or vi or something and are inherited from the NeXT days). Other examples are ctrl-d deletes forward, ctrl-h deletes backward; ctrl-right or left arrow jumps to the end/beginning of the line (not the sentence, like a/e); ctrl-n/ctrl-p jumps back/forward one line.


This is true and they are based on emacs. One of the great things I love about this is that each user can customize these to their liking in the ~/Library/KeyBindings directory. Here is more information about doing this as well as a nice dict file to make your emacs fingers happy. Very Happy
Back to top
kiwibird
Blue Pill


Joined: Mar 10, 2008
Posts: 1

PostPosted: Mon Mar 10, 2008 1:16 am    Post subject:

Um.. so how do I make NeoOffice recognize the keybindings file? (It seems really strange to make a Mac-version of a program and then _not_ include the Mac keybindings, I'm almost tempted to boot Windows for the few times I need to make a presentation, just to avoid having to learn a mashup of Windows and Mac keybindings)
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Mon Mar 10, 2008 8:15 am    Post subject:

kiwibird wrote:
Um.. so how do I make NeoOffice recognize the keybindings file? (It seems really strange to make a Mac-version of a program and then _not_ include the Mac keybindings, I'm almost tempted to boot Windows for the few times I need to make a presentation, just to avoid having to learn a mashup of Windows and Mac keybindings)


While this is a simple feature if you write a Mac application from the ground up, but that is not what NeoOffice is. Since NeoOffice has ported the massive Windows-based OpenOffice.org code, implementing such key bindings is not a trivial tasks and would involve significant changes throughout the OpenOffice.org code.

Unfortunately, due to limited funding and developer resources, the current scope of the NeoOffice project is limited to keeping a native version of OpenOffice.org running on Mac OS X and fixing OpenOffice.org feature bugs is outside that scope.

Patrick
Back to top
PavelS
Red Pill


Joined: Mar 23, 2008
Posts: 5

PostPosted: Thu Apr 03, 2008 4:58 pm    Post subject:

Have you already tested Java 1.6, whether Apple eliminated the bug related to key bindings? I can't try it myself, because my MacBook is 32-bit only and Java 1.6 Preview requires 64-bits.
Back to top
pluby
The Architect
The Architect


Joined: Jun 16, 2003
Posts: 11949

PostPosted: Thu Apr 03, 2008 6:02 pm    Post subject:

PavelS wrote:
Have you already tested Java 1.6, whether Apple eliminated the bug related to key bindings? I can't try it myself, because my MacBook is 32-bit only and Java 1.6 Preview requires 64-bits.


No, we have not done any work with Java 1.6 yet. Generally, we wait until a new Apple Java release is official before we start trying to get NeoOffice to support it as we have to work through all of the JNI hooks in our code and see which ones need to be changed or eliminated.

Patrick
Back to top
Display posts from previous:   
   NeoOffice Forum Index -> NeoOffice Development All times are GMT - 7 Hours
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Powered by phpBB © 2001, 2005 phpBB Group

All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest © Planamesa Inc.
NeoOffice is a registered trademark of Planamesa Inc. and may not be used without permission.
PHP-Nuke Copyright © 2005 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.