Re: [api-dev] Re: problem creating commandButton with events from macro

2007-01-31 Thread Frank Schönheit - Sun Microsystems Germany
Hi Christian, method 1: works only before I reopen the document. The control editor show no events attached that's because when you register a listener created by CreateUnoListener, then it is not persistent. You would need to add some macro to the OnLoad event of the whole document,

Re: [api-dev] Re: problem creating commandButton with events from macro

2007-01-31 Thread Frank Schönheit - Sun Microsystems Germany
Hi Christian, I still cannot see why #2 and #3 is not working though. /me too I've now tested this with OOo 2.1 on Suse 10.1 and I get the same rsult Did you try a) examining what getScriptEvents tells you when you registered an event via UI and b) what is written into the content.xml when

Re: [api-dev] Undo API

2008-01-08 Thread Frank Schönheit - Sun Microsystems Germany
Hello Daniel, (preface: Parts of this mail were written before Mathias gave his in-depth answer, so please apologize any duplicates you find ...) Is there some work going on currently on an undo API for extensions? Since I did not find any trace of it, I think I will try to create this API

Re: [api-dev] feature versions

2008-01-08 Thread Frank Schönheit - Sun Microsystems Germany
Hi Dietmar, I would like to suggest that the API includes a hint, since which OOo version it is available. It is well done in struct ControlCommand, but that is to my knowledge the only place. API documentation authors are required to add this information, and a lot more places than

Re: [api-dev] feature versions

2008-01-08 Thread Frank Schönheit - Sun Microsystems Germany
Hi Juergen, And of course XDialogProvider2 is a perfect example where the unpublished flag is wrong if it is really in the office since 2.0.4 Given that XDialogProvider2 derives from XDialogProvider, and both are still unpublished, I suggest to merge them (i.e. moving the methods from

Re: [api-dev] Undo API

2008-01-08 Thread Frank Schönheit - Sun Microsystems Germany
Hello Dániel, A malicious extension could simply send all the contents of your hard drive to its evil author and format it afterwards :). Even my benign Python extensions have found several ways to crash OpenOffice.org (the simplest way being an infinite loop). I think it is mostly hopeless

Re: [api-dev] Undo API

2008-01-09 Thread Frank Schönheit - Sun Microsystems Germany
Hi Robert, Nice idea. When you have this, then you can even add a context menu close context to the item, for exactly the case where the macro failed to close it. This way, we could prevent breaking the complete Undo mechanism in a document - at least the user is able to repair it, then.

Re: [api-dev] Undo API

2008-01-09 Thread Frank Schönheit - Sun Microsystems Germany
Hi Robert, There's more than this. In fact, there are actions on a document which are *not* covered by the native Undo operations. Especially via API, you can do things which will never appear in the Undo stack. I can talk about my domain here only (I could name you a few scenarios with form

Re: [api-dev] Bug in 2.4-dev / 680m2 ??

2008-01-23 Thread Frank Schönheit - Sun Microsystems Germany
Hi Cor, In 2.3.1 I can have the following line in the Basic IDE oBTWAddress = ThisComponent.getCurrentSelection.getRangeAddress and run from there. In 2.4-dev (690m2) it runs fine from Tools|Macro's|Run, but starting in the IDE produces a run time error: Property or Method not

Re: [api-dev] AWT: some questions concerning Toolkit inconsistencies

2008-02-29 Thread Frank Schönheit - Sun Microsystems Germany
Hi Carsten, Trying the same test with ordinary controls (controls that are listed in the dialog-model service manager) you will obtain a valid reference to the control-view in both cases (before and after the execute() call) Ok, something that I missed. Up to now I thought that controls are

Re: [api-dev] AWT: some questions concerning Toolkit inconsistencies

2008-02-29 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, But when the control model is instantiated this way, there is no control at all: XControlContainer::getControl() at the UnoControlDialog returns null. Also strange that the model instantiated this way has properties it does not have when instantiated at the global service manager

Re: [api-dev] new-style service constructors [comes from How to get the canonical path from a script URL...

2008-06-15 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, And even this is not completely safe in OOo Basic, as it is implementation specific; quoting Frank's in http://api.openoffice.org/servlets/ReadMsg?list=devmsgNo=18530 So, the bottom line is: createInstanceWithArguments[AndContext] *might* work, but if it doesn't (or stops working

Re: [api-dev] Staroffice basic library question

2008-08-02 Thread Frank Schönheit - Sun Microsystems Germany
Hi Craig, I have several spreadsheet documents that need to access a common set of staroffice basic macro routines that cannot be in a user application specific location (i.e. they cannot be in a user specific 'My Macros' library) I would like to be able to have the above mentioned

Re: [api-dev] (Carefully) changing legacy published API?

2008-08-06 Thread Frank Schönheit - Sun Microsystems Germany
Hi Thorsten et al. sorry for stepping in that late, was quite busy with other things recently. (And, partly, didn't know whether I *really* want to join this potentially big and ugly discussion :) Anyway, thanks for bringing up the topic. I can't but agree with you (and obviously with Jürgen)

Re: [api-dev] Equivalent to LogicToPixel(::Size, MAP_APPFONT) in css.awt.XUnitConversion

2008-09-19 Thread Frank Schönheit - Sun Microsystems Germany
HI Ariel, maybe it's too late at night and I can't see clearly, but how can we convert from css.awt.Size in Map AppFont unit to css.awt.Size in PIXEL using the css.awt.XUnitConversion? seems there is none ... Mind submitting an issue? And by the way the specification for

Re: [api-dev] Equivalent to LogicToPixel(::Size, MAP_APPFONT) in css.awt.XUnitConversion

2008-09-19 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, maybe it's too late at night and I can't see clearly, but how can we convert from css.awt.Size in Map AppFont unit to css.awt.Size in PIXEL using the css.awt.XUnitConversion? seems there is none ... Mind submitting an issue? which is the issue here? that in

Re: [api-dev] API discussion/announce in the API mailing list?

2008-10-20 Thread Frank Schönheit - Sun Microsystems Germany
Hi Bernard, Suggestion: There are now web sites that copy some of the mailing lists, so you can read them from time to time without subscription. Examples: http://www.mail-archive.com/[EMAIL PROTECTED]/ http://www.mail-archive.com/interface-announce%40openoffice.org/ and some dev lists :

Re: [api-dev] API discussion/announce in the API mailing list?

2008-10-20 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, the following message appeared in [EMAIL PROTECTED] ... my proposal[1]: why not announcing and discussing this topics directly in *this* API mailing list? (and let [EMAIL PROTECTED]/ [EMAIL PROTECTED] for internal C++ API or whatever name you give to the core C++ code)

Re: [api-dev] Xray problem with 3.0

2008-11-05 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, when running Xray under 3.0 Like: xray Thiscomponent i run in a error ( no suchEllementExecption) when Xray must open his dialog oLibContainer.LoadLibrary(Libname) the Xray dialog library is pressent the Libname = XrayTool Sounds a little bit like issue 94980:

Re: [api-dev] How to fill the Beamer (datbrowser) with SQL statement

2008-11-27 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, OK it works like a charm fine. but: when the Beamer is not present (ope,ed with the GUI) then i get a window on top of my writerdoc and not nicely docked on topof it. As a work around i open the Beamer with the Dispatcher. Can the Beamer been docked by the UNO API using

Re: [api-dev] How to move viewcursor into a Form.textbox

2008-12-03 Thread Frank Schönheit - Sun Microsystems Germany
Hello Fernand, I trye to get with some basic codelines the focus off a textbox in a form (the cursor must be ready to fill in a text) something like controlModel = ThisComponent.DrawPage.Forms.getByName( formName). _ getByName( controlName ) control =

Re: [api-dev] How to chenge column formats in DatsourceBrowser

2008-12-05 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, I hope Frank is still there :-) forcing me to answer your mails this way won't work forever :) I Try to change the column format in a Data Source Browser I used following code with no suces, the Formatkey off the column properties is changed but no visual changes oModel

Re: [api-dev] How to chenge column formats in DatsourceBrowser

2008-12-08 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, I hope Frank is still there :-) forcing me to answer your mails this way won't work forever :) Please do not see it as forcing where the hell sould i find the information who is apparently only in your head ?? But i understood alsoo your point, I will never do it

Re: [api-dev] No more lck file with HSQLDB Base ?

2008-12-08 Thread Frank Schönheit - Sun Microsystems Germany
HI Bernard, I am playing with DEV300m37 on Windows XP. I found that when I open a table or form in a Base document using internal HSQLDB, no xxx.lck file appears. In the same situation (same Base doc) in OOo 3.0 the .lck file does appear. Is it intentional ? That's not intentional, and

Re: [api-dev] Usage of UNO_QUERY_THROW

2008-12-11 Thread Frank Schönheit - Sun Microsystems Germany
Hi Daniel, Ah, by studying the sources, I learned that it should be uno::Reference XSomething xS2( xS1, uno::UNO_SET_THROW ); Right? Right. Ciao Frank -- - Frank Schönheit, Software Engineer frank.schoenh...@sun.com - - Sun Microsystems

Re: [api-dev] Re: Usage of UNO_QUERY_THROW

2008-12-16 Thread Frank Schönheit - Sun Microsystems Germany
Hi Daniel, What happens if UNO_QUERY_THROW is used instead? ... What is the reason you have introduced UNO_SET_THROW? It spares the queryInterface call. For a pattern like Reference XFoo xFoo = xBar-getSomeFoo(); // ensure that xFoo is not NULL, which would be a violation // of xBar's

Re: [api-dev] How to change the ActiveConnection of a already opened Form

2009-01-05 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, Also, in the scenario you described - two forms in the same database document - there should be no need at all to change the active connection of the already-loaded form. What do you want to achieve with this? Frank, thanks for the reply, the goal is to use OO as a front end

Re: [api-dev] How to change the ActiveConnection of a already opened Form

2009-01-05 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, OK I can follow so far, but can you see a other strategie to keep the users away from Tables and other Datbase stuff where valid information like Paswords etc... are been stored ? I was thinking on - Stroring the forms in a WritterDoc ? that would completely avoid the

Re: [api-dev] How set a Default Value to a FormControl ListBox

2009-01-05 Thread Frank Schönheit - Sun Microsystems Germany
Hello Fernand, but even manual entered list entries the famous button gives an ugly beep as respons, is this a bug or are am i doging something wrong ? hmmm, no problem here with using this Sounds like, well, at least a oddity of your installation/environment/version. Ciao Frank

Re: [api-dev] Using XDatabaseDocumentUI.loadComponent with BASIC

2009-01-07 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, Please tell me: Gives XDatabaseDocumentUI faster, better, saver connection than the old stuff ?? It gives a better, well-defined state. For instance, when you open a form using the XDatabaseDocumentUI, then it will be tracked by the application main window, and closed

Re: [api-dev] Using XDatabaseDocumentUI.loadComponent with BASIC

2009-01-08 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, BTW: do you see a way to do the inverse: closing the DB doc when last subcomponent is closed ? There's no built-in mechanism for doing this (we recently discussed this over there in us...@dba, IIRC). And for doing it via API, a mechanism to be notified of opened/closed sub

Re: [api-dev] Using XDatabaseDocumentUI.loadComponent with BASIC

2009-01-09 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, You see, I fail to see the overall picture how such a feature would look like, could you elaborate? Think on how Spreadsheets are protected. DB-doc GUImodifing protection by password DB-doc-SUBcomponent protection on GUI-USE (simpel: a Table, Query, Report, Form can been

[api-dev] Re: [allfeatures] changed/CWS fwk95 : Extended UNO AWT menu API

2009-01-17 Thread Frank Schönheit - Sun Microsystems Germany
Hi Carsten, With the following we work have been enhanced this API, by extending it with new interfaces. +com.sun.star.awt.XMenuExtended2 interface XMenuExtended2 { interface com::sun::star::awt::XMenuExtended; interface com::sun::star::awt::XMenu; ... Given that

Re: [api-dev] Re: [allfeatures] changed/CWS fwk95 : Extended UNO AWT menu API

2009-01-18 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, first: no offense intended with my mail. I perfectly understand the difficulties of extending an existing ... suboptimal API ... There is one problem with your solution, I don't want that we change an interface (XMenuExtended) incompatible which has been available since four

Re: [api-dev] Re: [allfeatures] changed/CWS fwk95 : Extended UNO AWT menu API

2009-01-19 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, Means: If existing API is unpublished, then IMO we should extend it incompatibly, if it becomes a little better / less ugly thereby I've found no way to change its ugliness without breaking API design rules. Don't know what you have in mind. Yes, doing it completely right

Re: [api-dev] How to attach new Model to old Controller

2009-02-18 Thread Frank Schönheit - Sun Microsystems Germany
Hi Daniel, Q1: Why can't I retieve the XFrame starting from the top (XDesktop) while I can get it starting from the bottom (XModel)? Hard to answer without knowing how exactly you tried to retrieve the frame. I'd say that iterating over the frames at the desktop, and checking for a frame

Re: [api-dev] How to attach new Model to old Controller

2009-02-19 Thread Frank Schönheit - Sun Microsystems Germany
Hi Daniel, With regards to getting the frame from the desktop I used the xDesktop.getCurrentFrame() API. This returned null. getCurrentFrame is almost always a bad idea. It denotes the currently active frame, and this is a term which cannot be reliably defined, really, for instance because the

Re: [api-dev] How to attach new Model to old Controller

2009-02-19 Thread Frank Schönheit - Sun Microsystems Germany
Hi Daniel, I guess there is a theoretical API and a real api. Well, as Mikhail said, the API definition allows for rejecting an attempt to attach a new model. As a secondary thought, I'd say that a VetoException or something like this would have been a better API design, since it would allow

Re: [api-dev] No more lck file with HSQLDB Base ?

2009-02-23 Thread Frank Schönheit - Sun Microsystems Germany
Hi Bernard, Issue 97032 has target OOo 3.1 and indicated as verified fixed in CWS dba31h. Now, dba31h_OOO310 is integrated into OOO310m2 but the problem is still here : no lock file when opening an odb with integrated hsql database. Was the patch forgotten ? I re-opened the issue, and

Re: [api-dev] Regresion in User Defined DocumentInfo

2009-03-16 Thread Frank Schönheit - Sun Microsystems Germany
Hi Fernand, now i have to use oDocuInfo.GetpropertieValue( PMG_StylesVakjes) Changing this few lines is not the problem, but The code is around in Thousands of documents :-) should i start changing my code or can this be fixed ? I'd say this is an API compatibility issue. Try

Re: [api-dev] How to find containing row of an XTextRange

2009-04-02 Thread Frank Schönheit - Sun Microsystems Germany
Hi Devin, The TextTable property was just what I was looking for. I still can't find this in the online API reference though. Does that mean it's private or depreciated? ... Hi Peter. That wasn't what I meant. Why isn't this property documented? It seems it isn't for public use and

Re: [api-dev] How to find containing row of an XTextRange

2009-04-02 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, Now there is a XTextTableSupplier interface, which has a method getTextTable. So maybe your object supports this interface? no, he is talking about all the SwXTextCursor undocumented properties: Okay, I should have followed the thread more closely before jumping in :) Thanks

Re: [api-dev] Thinking about an API deprecation process

2009-04-29 Thread Frank Schönheit - Sun Microsystems Germany
Hi Thorsten, as a general preface, let me say that I agree to Jürgen that we should separate UNO API incompatibility from UDK API incompatibility. While I think that some ideas can be applied to both, my gut feeling is that both topics are too different to be discussed together. preface II:

Re: [api-dev] Thinking about an API deprecation process

2009-04-29 Thread Frank Schönheit - Sun Microsystems Germany
Hi Thorsten, I buy that. But as I said elsewhere, in my book there's a fundamental difference between c++ extensions and e.g. Java- or Python-based ones: it is *much* easier to break compatibility for c++ extensions, and handling them suck when dealing with cross-platform extensions. Given

Re: [api-dev] Thinking about an API deprecation process

2009-04-29 Thread Frank Schönheit - Sun Microsystems Germany
Hi Thorsten, well, Win32 is only one platform, and experience tells that in general, c++ extension *do* break between releases. But you're right, that's not necessarily caused by ABI changes in the strict meaning of the word, a case in point is the 3 layer OOo rework. Hu?

Re: [api-dev] Thinking about an API deprecation process

2009-04-29 Thread Frank Schönheit - Sun Microsystems Germany
Hi Thorsten, Who decides? Difficult ... Having a gatekeeper (or multiple fatekeepers) does not really sounds feasible. I would hope that discussing the changes in public until a consensus is reached would work out. Uh, well. While I appreciate striving for consent, this tends to not work

Re: [api-dev] Thinking about an API deprecation process

2009-04-30 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, I'd say we need a set of highly proficient and highly respected architects, whose opinion should, at least, be weighted high. No, please not! Actually I wasn't kidding as much as Thorsten supposed :-\ No, I do not really think that a formal process such as 3 out of those 5

Re: [api-dev] Proposal: first convention to discuss API changes in the future

2009-05-14 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, It makes sense that if someone adds a new member, the @since tag is also added, and autodoc respects it; not the case nowadays: cf. http://svn.services.openoffice.org/opengrok/xref/DEV300_m47/offapi/com/sun/star/accessibility/AccessibleRelationType.idl#117 vs.

Re: [api-dev] Proposal: first convention to discuss API changes in the future

2009-05-14 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, done, http://www.openoffice.org/issues/show_bug.cgi?id=101932 Seen and ttargeted it, thanks. another thing that has to be fixed (if changes to published API are going to be allowed) is one of the sdk tools that won't let you do that (now I can't recall if it was the idlc that

Re: [api-dev] Proposal: first convention to discuss API changes in the future

2009-05-14 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, I have several changes in mind for the awt module (including my enhanced menu API); this module has several non-senses (like a top window not being a window, and the like). I volunteer myself for fixing the ones in my list (once API changes are allowed). Ah, great, that's most

Re: [api-dev] Proposal: first convention to discuss API changes in the future

2009-05-15 Thread Frank Schönheit - Sun Microsystems Germany
Hi Juergen, mmh, i would also think about converting the services in multiple inheritance interfaces with type safe get/set function or even attributes. ... When we do API changes we should always check if it make sense or is possible to migrate to multiple inheritance interfaces without

Re: [api-dev] Proposal: first convention to discuss API changes in the future

2009-05-15 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, If major releases happen every 3 years, then allowing API changes only on a mayor release does not make much sense to me. That depends from where you look at it. We always must consider that API users expect API stability, so we need to find a good compromise. Changing APIs

Re: [api-dev] Proposal: first convention to discuss API changes in the future

2009-05-15 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, My personal take on API changes (changes I would like to suggest or to do) is more restrictive anyway, but that's only me. If possible I always would prefer changes that just need recompilations (what usually als means that Basic macros don't need any work at all as the use

Re: [api-dev] Proposal: first convention to discuss API changes in the future

2009-05-15 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, For a very good reason, we have a train model - integrate what's done, not more, not less - for all other code changes. The lesson we learned for features is that precision landings - I want to have that finished for release x.y - are doomed to fail too often. Why should this be

Re: [api-dev] Macro ODB documents

2009-06-05 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, I still think that defining ThisComponent as the component from which the macro was invoked (as opposed to the component which the macro is embedded into) was the better choice, and causes less hassle. Finally, this means that only newly written code needs to care for the new

Re: [api-dev] Macro ODB documents

2009-06-05 Thread Frank Schönheit - Sun Microsystems Germany
Hi Paolo, Not necessarily the form designer has to be the same component used for showing a runtime form instance (IMHO this should be an implementation detail) ... Speaking of runtime forms, again I don't see the necessity for having word processor capabilities (menu, toolbars, online

Re: [api-dev] Macro ODB documents

2009-06-05 Thread Frank Schönheit - Sun Microsystems Germany
Hi Paolo, Regarding the ThisDatabaseDocument thing, I'm experimenting. The open() method is very simple and straightforward and I'm sure that users will be very happy of it, but I noticed a possible problem. Not sure which open method you refer to, ThisDatabaseDocument doesn't have one.

Re: [api-dev] Macro ODB documents

2009-06-08 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, This was one design decision we had to make when Base was created in the current form. Finally, the decision for SDI was because of technical constraints, since OOo doesn't have an infrastructure for MDI. Chosing SDI in favor of MDI was not because we didn't have an

Re: [api-dev] Macro ODB documents

2009-06-08 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, This is forbidden already: The Run Macro dialog lists the global macros, plus the ones from the current document, nothing else. You still can execute the macros from Tools-Macro-Organize. Ah, right. I thought that was forbidden, too. I remember having seen some error dialog when

[api-dev] adding a method to a published interface

2009-06-29 Thread Frank Schönheit - Sun Microsystems Germany
Hi, would adding a method to an existing published interface be considered too incompatible for a 3.2 release? In particular, css.awt.XView has a method setZoom, but not a getZoom, which I'd like to add. I could create a crutch called XView2, deriving from XView, having only this one said

Re: [api-dev] Re: [interface-discuss] adding a method to a published interface

2009-06-30 Thread Frank Schönheit - Sun Microsystems Germany
Juergen, Ariel, to make it short, i would support you to add it. If we make the change we should start with a new wiki page to document the change and a migration path even if it would be trivial. okay. What location do you suggest? Do we already have an entry point in the wiki to the

Re: [api-dev] Re: [interface-discuss] adding a method to a published interface

2009-06-30 Thread Frank Schönheit - Sun Microsystems Germany
Hi Ariel, I didn't have time to understand the reasons given for adding a FilterOperator2, carrying with it a TableFilterField2 and a XSheetFilterDescriptor2; but the names just tell me there was no agreement. Well, the agreement really was that for a major release, any API changes can be

Re: [api-dev] adding a method to a published interface

2009-06-30 Thread Frank Schönheit - Sun Microsystems Germany
Hi Malte, I disagree with doing selected enhancements in single css.awt interfaces. ... If people agree on incompatible changes, I would prefer to clean up all css.awt API and add missing get- methods. I wouldn't start to do it here and there when somebody stumbles over it. And the next

Re: [api-dev] adding a method to a published interface

2009-06-30 Thread Frank Schönheit - Sun Microsystems Germany
Hi Malte, Well, you attended the meeting about AWT improvements with Carsten many month (or years?!) ago, where we discussed this. Maybe you can dig out what our conclusion was that time, maybe with some arguments? ;) Then feel free to use that information and start a discussion thread

Re: [api-dev] adding a method to a published interface

2009-06-30 Thread Frank Schönheit - Sun Microsystems Germany
Hi Malte, I didn't say I want to stay w/o getter methods, but that I want to introduce them. But then not just in that one place, because I remember that people complained about missing getter methods in many AWT interfaces. So my point was to introduce them in all AWT interfaces where they

Re: [api-dev] adding a method to a published interface

2009-07-06 Thread Frank Schönheit - Sun Microsystems Germany
Hi Mathias, Is there a good reason to not do the changes incrementally? Yes, there is a very good reason. Every incompatible change causes pain, no matter how many individual changes it contains. Indeed. Changing XView to contain that additional method creates pain now. Creating an XView2