Re: [dev] OLE, data type hyper and returned vt value !?
Marten Feldtmann schrieb: Joachim Lingner schrieb: Hi Marten, Marten Feldtmann wrote: When running around in the reflection system of OpenOffice 2.x I came across the following problem: Some constants have adefined data type hyper, which means signed 64 bit values. When I query the value for that constant I get a dispatched (is this the right name) with a vt type = 14. I ran around and looked for that definition: 14 and found in my development tool and some texts from Microsoft, that the value for signed 64-bit values is 0x14 - which means 20 and not 14. Int 64 is no valid automation type: http://msdn2.microsoft.com/en-us/library/aa367129.aspx Therefor Decimal should be used. See Developers Guide: http://api.openoffice.org/docs/DevelopersGuide/ProfUNO/ProfUNO.xhtml#1_4_4_7_Type_Mappings paragraph: Mapping of hyper and Decimal. Since automation bridge converts the arguments to the expected type it should also be possible to provide 16 or 32 bit integers where a hyper is expected. Then it is a bug within the automation bridge ... as an example: com.sun.star.embed.Aspects In case there are no 100% equivalent types in two different type systems (oleautomation UNO) one has to tweak a little. The Decimal should cover the value space of a hyper and can therefore be used on the oleautomation side when calling an UNO method which requires an hyper argument. Joachim Marten - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [dev] OLE, data type hyper and returned vt value !?
Joachim Lingner schrieb: In case there are no 100% equivalent types in two different type systems (oleautomation UNO) one has to tweak a little. The Decimal should cover the value space of a hyper and can therefore be used on the oleautomation side when calling an UNO method which requires an hyper argument. And yes, I noticed my fault again ... the returned 14 value IS VT_DECIMAL ... apologize for my misunderstanding Marten - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[dev] build bot install-time failures, a way to see what failed ?
Is there any way in the build-bot infrastructure to get a hold of the install time log on failure, e.g. I have a build that fails at http://buildbot.go-oo.org/buildbot/Win-XP/builds/136/step-shell_5/1 with ERROR: ERROR: Could not register all components for file services.rdb (gid_Starregistry_Services_Rdb)! Any chance the buildbot could be tweaked to just cat the install log file of e.g. d:/termite/slavedir/Win-XP/workdir/instsetoo_native/wntmsci11.pro/OpenOffice/msi/logging/en-US/log_SRC680_en-US.log at the end of a build so we can see what fails. C. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[dev] Height/width of cells in complex tables
Hi, We currently use the OOo api (C++ SDK) to parse a writer document to generate accessible html. I need to obtain the height, width, column span and row span of each split/merged cell. I know from the dev guide (p529) that cells can contain text or rows. I can find the tablecolumnseparators for each row and iterate over each cell. However, I'm not sure how to relate the seperator value to a particular cell. If I could access a row within a cell I should be able to figure out the cell widths. So the question is - how do I access/enumerate a row within a cell? Best regards, Ian Take the Internet to Go: Yahoo!Go puts the Internet in your pocket: mail, news, photos more. http://mobile.yahoo.com/go?refer=1GNXIC - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[dev] Add existing textfield
Hi all. I have some user textfileds that I added to a document using something like this XDependentTextField xUserField = (XDependentTextField)UnoRuntime.queryInterface( XDependentTextField.class, mxDocFactory.createInstance(com.sun.star.text.TextField.User)); XPropertySet xMasterPropSet = (XPropertySet)UnoRuntime.queryInterface(XPropertySet.class, mxDocFactory.createInstance(com.sun.star.text.FieldMaster.User)); xMasterPropSet.setPropertyValue ( Name, SGT_Com_ + compoNom); xUserField.attachTextFieldMaster ( xMasterPropSet ); mxDocText.insertTextContent(cursorDocumento, xUserField, false); Then I removed that user field from the visible document, and if I press ctrl+F2 I can see the field is there. Up to here it's everything ok The thing is that later in time I want to add that field again to the same document, but I can't use the lines above, cause they gave me an IllegalArgumentException, because that field already exists. So, I would like to know how can I add the field again to the document. Thanks
Re: [dev] Sample code
Hi Nikos, On Tuesday, 2007-10-16 11:00:00 -0700, Nikos Trivlis wrote: I think I have fixed the bugs in my code. Remember is c-like and not c (I used = instead of ==) Since I am not a pro programmer I would like to explain to you the logic: I understand the logic of your attempt, I just don't get what it would be good for, it is clearly not a candidate to replace existing code. The OOoCalc POWER implementation uses the compilers' pow() function, which usually have far more sophisticated implementations than your handmade loop. You might want to take a look at the GNU libc implementation, for example. Eike P.S.: Please consider to subscribe to the mailing lists you're posting to. By doing so you won't miss replies that are directed to the list only. When answering, please reply only to the list (Reply-To header is set), not to my personal account. Thanks. -- OOo/SO Calc core developer. Number formatter stricken i18n transpositionizer. SunSign 0x87F8D412 : 2F58 5236 DB02 F335 8304 7D6C 65C9 F9B5 87F8 D412 OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS Please don't send personal mail to this [EMAIL PROTECTED] account, which I use for mailing lists only and don't read from outside Sun. Use [EMAIL PROTECTED] Thanks. pgprkxTpLe1Br.pgp Description: PGP signature
Re: [dev] Contributing to OOo - [ Was : Re: [dev] PDF links regressions needing attention (bug 54906 et al)
Hi Cor, I want so second that. Consolidating issues is very helpful for us and it can be a valuable contribution. As I assume that people doing this have some interest in seeing something done in return ;-) I would like to add that such contributions should be aligned with the project lead. The developers should state when resources will be available to work on some of the remaining issues so that nobody will work for nothing and gets frustrated. Ciao, Mathias Cor Nouws wrote: Hi, [ Hé, great, a reply to this mail ;-) ] I just queried IssueTracker for 'indent' in Writer. Only 63 issues. And somewhere in between one or more instances of the problem I'm facing. Nonetheless, it makes me think about the suggestion below. In short: - could people willing to contribute, be of help with bringing some line in related issues? - pls see my further remarks below! If so, this could be easily added to the 'how you can help' info on our website. Kindest regards - and keep up all the good work (was nice seeing Dieters' Glance and all the good stuff mentioned there) - Cor Cor Nouws wrote (30-5-2007 17:40) Hi all, Mike's mail brings me to an idea: Mike Stockman wrote: [...] I'm not a programmer, so I can't contribute much to the solution (except for some QA, and examples), but I'd really like to see this addressed. This morning I happened to look through a query of PDF issues. ( 274. looking for some font info, before deciding to submit a new one or not. I think I took about 25 issues apart, just by the summary, for further reading.) Some time ago I investigated a number of 'window'-related issues. These two exepriences, give me the idea that maybe something on the page contributing to OOo [1] can be improved, added. Maybe there is a nice task for people, that are not really sharp ( ;-) ) in programming, but do understand it, have understanding of functions, of interfaces. Those people, when having time and motivation, could pick up a bunch of issues topic (unconfirmed, old, new ...) around one, and prepare some functional analyses of wishes, possibilities, difficulties. Preparation for specs. This is not the same as programming [2]. Of course, care have to be taken to be in line with - requirements - programming resources. But a good preparation always costs time first (new people) and saves time later (programmers and qa). Any thoughts if it is an idea to update [1] ? Thanks, Cor [1] http://contributing.openoffice.org/index.html [2] http://contributing.openoffice.org/programming.html -- Mathias Bauer (mba) - Project Lead OpenOffice.org Writer OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS Please don't reply to [EMAIL PROTECTED]. I use it for the OOo lists and only rarely read other mails sent to it. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[dev] Development at a Glance - Weekly Update CW42
Hi, here is the weekly update for calendar week (CW) 42: http://blogs.sun.com/GullFOSS/entry/development_at_a_glance_weekly33 Regards, Dieter - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [dev] can anybody explain the funtioan of selectionManager call
gaopeng wrote: hi , all I want to know how to implement myself clipboard on linux platform , I have read clipboard source code of the openoffice.org , but I still have some doubts for some code . I searched these , but there is not in the url http://api.openoffice.org/ . my question is following : 1: what are we must keep to when we add clipboard functional into ourself apllication on the linux ? I'm not sure if I understood that question correctly. We already have a complete implementation for clipboard on all supported platforms and it gives a UNO abstraction of the clipboard content. So whatever you want to keep in application code it would be based on that abstraction. 2: can anybody tell me where I can get more informaton about the class SelectionAdaptor/SelectionManager I think you are referring to the internal implementation of the X11 clipboard. I think that is best answered on the [EMAIL PROTECTED] mailing list. Ciao, Mathias -- Mathias Bauer (mba) - Project Lead OpenOffice.org Writer OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS Please don't reply to [EMAIL PROTECTED]. I use it for the OOo lists and only rarely read other mails sent to it. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [dev] How to get notified, when document's URL changes
Matthias B. wrote: I'm looking for a way to get notified when a document's URL (XModel.getURL()) changes, usually after the user saves the document via save as (or save in case of a new document). I tried an XStorageChangeListener, but it's not triggered in this case. The only other thing I can think of is to catch the dispatches for Save and SaveAs, but that's not pretty and doesn't catch changes to the URL via API. You can try the document event OnSaveAsDone. Ciao, Mathias -- Mathias Bauer (mba) - Project Lead OpenOffice.org Writer OpenOffice.org Engineering at Sun: http://blogs.sun.com/GullFOSS Please don't reply to [EMAIL PROTECTED]. I use it for the OOo lists and only rarely read other mails sent to it. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[dev] Fwd: Anyone help me necessary
Note: forwarded message attached. - Need a vacation? Get great deals to amazing places on Yahoo! Travel. - Building a website is a piece of cake. Yahoo! Small Business gives you all the tools to get online.---BeginMessage--- I use open office.org 2 , I create forms and table one of this forms have name a report its retrieve the data from the table and its success to retrieve but my problem when I print the report form the data in the text is Arabic , the Pinter print the Arabic language reflect such as I see the data (ÇáäÊíÌå) but the printer print (åÌíÊäáÇ) I change my computer to try to solve this problem but I found the reflection of the words is disappear but appear another problem ...when I print the repot form the name of text (ÇáäÊíÌå) is disappear under the text I do not know how to solve this problem if anyone know how to solve please contact me though this mail Thanks a lot - Catch up on fall's hot new shows on Yahoo! TV. Watch previews, get listings, and more!---End Message--- - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [dev] Add existing textfield
Hi Juan, Juan Emilio Gabito escribió: Hi all. I have some user textfileds that I added to a document using something like this XDependentTextField xUserField = (XDependentTextField)UnoRuntime.queryInterface( XDependentTextField.class, mxDocFactory.createInstance(com.sun.star.text.TextField.User)); XPropertySet xMasterPropSet = (XPropertySet)UnoRuntime.queryInterface(XPropertySet.class, mxDocFactory.createInstance(com.sun.star.text.FieldMaster.User)); xMasterPropSet.setPropertyValue ( Name, SGT_Com_ + compoNom); xUserField.attachTextFieldMaster ( xMasterPropSet ); mxDocText.insertTextContent(cursorDocumento, xUserField, false); Then I removed that user field from the visible document, and if I press ctrl+F2 I can see the field is there. Up to here it's everything ok The thing is that later in time I want to add that field again to the same document, but I can't use the lines above, cause they gave me an IllegalArgumentException, because that field already exists. So, I would like to know how can I add the field again to the document. Thanks BEFORE creating a field master, you should use XTextFieldsSupplier::getTextFieldMasters(); it returns an XNameAccess, so if the collection of TextFieldMaster instances defined in the document has *already* a text field master with that name (== XNameAccess::hasByName(TextFieldMaster_NAME) returns true), then you GET it by name; if *not*, you can instantiate it, that is create a new one. Remember that you must use the fully qualified name, for example: com.sun.star.text.FieldMaster.SetExpression.OOoMathFórmula is the fully qualified name for a field master, type SetExpression, name OOoMathFórmula (with the accent included). Bellow you can find a complete example, it supposes that the current component in the desktop is a text document of course (and that you can bootstrap a running office!). The first time you run it, it will create the field master; the next time you run it on the same doc., it will get it by name. Hope it helps! Bye, Ariel // package ar.com.arielconstenlahaile.test.embed; import com.sun.star.comp.helper.Bootstrap; import com.sun.star.uno.XComponentContext; import com.sun.star.uno.UnoRuntime; import com.sun.star.frame.XDesktop; import com.sun.star.lang.XServiceInfo; import com.sun.star.lang.XComponent; import com.sun.star.lang.XMultiServiceFactory; import com.sun.star.text.XTextDocument; import com.sun.star.text.XText; import com.sun.star.text.XTextContent; import com.sun.star.text.XTextRange; import com.sun.star.text.XTextCursor; import com.sun.star.text.XTextEmbeddedObjectsSupplier; import com.sun.star.text.ControlCharacter; import com.sun.star.text.SetVariableType; import com.sun.star.text.TextContentAnchorType; import com.sun.star.text.XDependentTextField; import com.sun.star.text.XTextFieldsSupplier; import com.sun.star.style.NumberingType; import com.sun.star.document.XEmbeddedObjectSupplier; import com.sun.star.beans.XPropertySet; import com.sun.star.container.XNamed; import com.sun.star.container.XNameAccess; import com.sun.star.container.XEnumerationAccess; import com.sun.star.util.XRefreshable; /** * * @author ArielConstenlaHaile */ public class TextFieldMasterTest { private XComponentContext xContext; private XTextDocument xTextDocument; public TextFieldMasterTest(XTextDocument xTextDocument) throws com.sun.star.uno.Exception { this.xContext = xContext; this.xTextDocument = xTextDocument; XText xText = xTextDocument.getText(); XTextCursor xTextCursor = xText.createTextCursorByRange(xText.getEnd()); xText.insertControlCharacter( xTextCursor, ControlCharacter.PARAGRAPH_BREAK, Boolean.FALSE); xText.insertString(xTextCursor, F\u00F3rmula N\u00B0 , Boolean.FALSE); String fieldName = OOoMathF\u00F3rmula; XPropertySet xFieldMaster = createMasterSetExpression( xTextDocument, fieldName, (byte) -1, , SetVariableType.SEQUENCE); XDependentTextField xSetExpressionField = createSetExpression( xTextDocument, xFieldMaster, fieldName + +1, SetVariableType.SEQUENCE, 4, NumberingType.ARABIC); xText.insertTextContent(xTextCursor, xSetExpressionField, Boolean.FALSE); xText.insertString( xTextCursor, , Boolean.FALSE ); XTextEmbeddedObjectsSupplier xTextEmbeddedObjectsSupplier = (XTextEmbeddedObjectsSupplier) UnoRuntime.queryInterface( XTextEmbeddedObjectsSupplier.class, xTextDocument); XNameAccess xTextEmbeddedObjects = xTextEmbeddedObjectsSupplier.getEmbeddedObjects(); insertMathFormula( xTextDocument, xTextCursor.getEnd(), { { 6 over 7 times 8 } + 5 } over 10, createUniqueNameForContainerElement(xTextEmbeddedObjects,OOoMathFormula));