Re: [dev] Using matrices for rotation of graphical objects

2010-03-24 Thread Regina Henschel

Hi Thibault,

Thibault Vataire schrieb:

Hi,

I'm working on an extension that allow to rotate images in Writer, in the 
meanwhile that this function was added to OpenOffice.org.
Some users asked me to add predefined values like rotate 90°, but I encounter 
some difficulties to use the matrices for rotation.
I've found how to compute values for the first and the second column of the 
matrix, but not for the third.

These values seems to be the new position of the initial upper left corner of 
the shape.

Is somebody know how to compute these values ?



I'm a little bit confused. If you have a Draw shape, then there is a 
transformation matrix, but that is not a new function. If you have a 
TextGraphicObject, then there is no transformation matrix. So what kind 
of object you are speaking about?


kind regards
Regina

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



[dev] Using matrices for rotation of graphical objects

2010-03-24 Thread Thibault Vataire
Hi,

I'm working on an extension that allow to rotate images in Writer, in the 
meanwhile that this function was added to OpenOffice.org.
Some users asked me to add predefined values like rotate 90°, but I encounter 
some difficulties to use the matrices for rotation.
I've found how to compute values for the first and the second column of the 
matrix, but not for the third.

These values seems to be the new position of the initial upper left corner of 
the shape.

Is somebody know how to compute these values ?

Best regards,

Thibault Vataire.

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



Re: [dev] 65,000 lines on calc

2010-03-24 Thread Camillem
Alexandro Colorado a écrit :
> when did OOo Calc (what version #) get past the 65,000 limit on spreadsheets?
>   
If you mean the 65536 lines limit, I hasn't yet (at least not in Dev75)

http://www.openoffice.org/issues/show_bug.cgi?id=30215

Interesting details on Kohei Yoshida's blog :

http://kohei.us/2010/02/20/increasing-calcs-row-limit-to-1-million/

If you really need it now, you can give a try to Go-oo version.

HTH ,
Camille


-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



[dev] 65,000 lines on calc

2010-03-24 Thread Alexandro Colorado
when did OOo Calc (what version #) get past the 65,000 limit on spreadsheets?

-- 
Alexandro Colorado
OpenOffice.org Español
"Support this 31st March - Document Freedom Day "
http://www.documentfreedom.org

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



Re: [dev] java rdf problem again

2010-03-24 Thread Niklas Nebel

On 03/24/10 16:33, Andrea Chiumenti wrote:

XURI nodeTableName = URI.create(m_xContext, "gam3:tableName");



The code generates this rdf file:


http://www.w3.org/1999/02/22-rdf-syntax-ns#";>
  http://.wingstech.it/gam3/v1.0";>
A_TABLE
12345
  


What I needed was instead something like this:


http://www.w3.org/1999/02/22-rdf-syntax-ns#";>
  http://.wingstech.it/gam3/v1.0";>
A_TABLE
12345
  



In the URI.create call, the parameter should include the namespace URI, 
not the prefix. A prefix (like "ns1") is then generated. You can see it 
in the example output: If "gam3:" was replaced by something like 
"http://www.wingstech.it/gam3/v1.0/";, it would be equivalent to the 
second fragment (except for the namespace definition, which is missing 
there).


Niklas

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



[dev] java rdf problem again

2010-03-24 Thread Andrea Chiumenti
Hello,
I've a problem with following code:

try
{
XDocumentMetadataAccess xDMA = (XDocumentMetadataAccess)
UnoRuntime.queryInterface(XDocumentMetadataAccess.class, xModel);
XURI xType = URI.create(m_xContext, "http://.wingstech.it/gam3/v1.0
");
try {
xDMA.removeMetadataFile(URI.create(m_xContext, xDoc.getURL() +
"/gam3/dbinfo.rdf"));
}
catch (java.lang.Exception eRemove)
{
}

XURI xGraphName = xDMA.addMetadataFile("gam3/dbinfo.rdf", new XURI[]
{
xType
});
XNamedGraph xGraph = xDMA.getRDFRepository().getGraph(xGraphName);

XURI nodeTableName = URI.create(m_xContext, "gam3:tableName");
XLiteral valTableName = Literal.create(m_xContext, "A_TABLE");
xGraph.addStatement(xType, nodeTableName, valTableName);

XURI nodeTableId = URI.create(m_xContext, "gam3:tableId");
XLiteral valTableId = Literal.create(m_xContext, "12345");
xGraph.addStatement(xType, nodeTableId, valTableId);
}
catch (java.lang.Exception e)
{
e.printStackTrace();
showMessageError("ERROR rdf", e);
}


The code generates this rdf file:



http://www.w3.org/1999/02/22-rdf-syntax-ns#";>
  http://.wingstech.it/gam3/v1.0";>
A_TABLE
12345
  


What I needed was instead something like this:


http://www.w3.org/1999/02/22-rdf-syntax-ns#";>
  http://.wingstech.it/gam3/v1.0";>
A_TABLE
12345
  


How can I do ?

Thanks in advance,
kiuma


Re: [dev] Exception on trying to set an rdf metadata in java

2010-03-24 Thread Niklas Nebel

On 03/24/10 13:23, Andrea Chiumenti wrote:

Object xMetafield =
xDocFactory.createInstance("com.sun.star.text.textfield.MetadataField");
XText xMetafieldText =
(XText)UnoRuntime.queryInterface(XText.class, xMetafield);
xMetafieldText.setString(""); // clear the field: delete
all content  <--- LINE 110


The field must be inserted before accessing its content.

Niklas

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



Re: [dev] Exception on trying to set an rdf metadata in java

2010-03-24 Thread Stephan Bergmann

On 03/24/10 13:23, Andrea Chiumenti wrote:

try
{
XMultiServiceFactory xDocFactory =
(XMultiServiceFactory)UnoRuntime.queryInterface(XMultiServiceFactory.class,
xDoc);
Object xMetafield =
xDocFactory.createInstance("com.sun.star.text.textfield.MetadataField");
XText xMetafieldText =
(XText)UnoRuntime.queryInterface(XText.class, xMetafield);
xMetafieldText.setString(""); // clear the field: delete
all content  <--- LINE 110
XTextCursor xCursor = xMetafieldText.createTextCursor();
xMetafieldText.insertString(xCursor, "evviva", true);


}
catch (java.lang.Exception e)
{
e.printStackTrace();
}


--->>>

com.sun.star.uno.RuntimeException:
at com.sun.star.bridges.jni_uno.JNI_proxy.dispatch_call(Native
Method)
at com.sun.star.bridges.jni_uno.JNI_proxy.invoke(JNI_proxy.java:178)
at $Proxy18.setString(Unknown Source)
at it.wingstech.gam.Saver.dispatch(Saver.java:110)


What is it ?


Looks like the (C++) implementation of service 
com.sun.star.text.textfield.MetadataField throws a 
com.sun.star.uno.RuntimeException (with an empty explanatory Message) 
when you call its setString method.  (That is, it looks like the JNI UNO 
bridge just transports the exception back from the called side, rather 
than the JNI UNO bridge having internal problems and generating the 
exception itself.)  Maybe some metadata domain expert can step in.


and is it correct that I'm not able to resolve 
com.sun.star.text.textfield.MetadataField from java ?


What do you mean by that?

-Stephan

-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



[dev] Exception on trying to set an rdf metadata in java

2010-03-24 Thread Andrea Chiumenti
Hello I'm having this problem

try
{
XMultiServiceFactory xDocFactory =
(XMultiServiceFactory)UnoRuntime.queryInterface(XMultiServiceFactory.class,
xDoc);
Object xMetafield =
xDocFactory.createInstance("com.sun.star.text.textfield.MetadataField");
XText xMetafieldText =
(XText)UnoRuntime.queryInterface(XText.class, xMetafield);
xMetafieldText.setString(""); // clear the field: delete
all content  <--- LINE 110
XTextCursor xCursor = xMetafieldText.createTextCursor();
xMetafieldText.insertString(xCursor, "evviva", true);


}
catch (java.lang.Exception e)
{
e.printStackTrace();
}


--->>>

com.sun.star.uno.RuntimeException:
at com.sun.star.bridges.jni_uno.JNI_proxy.dispatch_call(Native
Method)
at com.sun.star.bridges.jni_uno.JNI_proxy.invoke(JNI_proxy.java:178)
at $Proxy18.setString(Unknown Source)
at it.wingstech.gam.Saver.dispatch(Saver.java:110)


What is it ? and is it correct that I'm not able to resolve
com.sun.star.text.textfield.MetadataField from java ?


Re: [dev] Transforming the Hyperlink bar in a websearch toolbar

2010-03-24 Thread MOULIN Camille
Mathias Bauer a écrit :
> MOULIN Camille wrote:
> > Hi Mathias, Mathias Bauer a écrit : [...]
> >> Where do you see the Hyperlink Bar not behaving like other
> >> toolbars?
> >
> > A"regular" toolbar has a drop down menu on the right end, allowing
> > you to choose the buttons you want to display, you can (un)anchor it,
> > move it around, etc. That means also that if it's narrow enough, you
> > can stick it to the right of your Standard toolbar.
> That's not entirely correct. The configuration menu is shown only for
> configurable toolbars and there are "regular" toolbars that are not
> configurable also, e.g. toolbars in extensions.
> OK, you want to have the hyperlink bar configurable.
> > Please have a look at the pictures below to see what I mean
> >
> > http://wiki.services.openoffice.org/wiki/User:Camillem/MyDrafts#Before
> >  and
> > http://wiki.services.openoffice.org/wiki/User:Camillem/MyDrafts#After
> >
> >> I mean, it's indeed a different implementation (because the
> >> controls are not independent from each other and so the toolbar
> >> itself implements some control logic), but until now I didn't see
> >> any difference from a UX point of view.
> >
> > Well, my question was also from a developper point of view : I think
> > this change would be beneficial to OOo (see
> > http://wiki.services.openoffice.org/wiki/User:Camillem/MyDrafts#Web_search_Toolbar
> > for more details), but I'm wondering if it's worth the effort.
> There are two ways to implement that feature: convert the hyperlink bar
> into a "regular toolbar" or extend the SfxChildWindow based
> implementations to support toolbars. Probably the latter would be a
> waste of time as the code is planned to be replaced. For a "regular
> toolbar" all code currently in the hyperlink bar class must be moved
> into the controllers - a quite challenging task.

Thanks very much for these details

> > That's why I was asking how long would it take to implement such a
> > change and what level of OOo knowledge would it require (as the
> > specificity of the implementation let me suppose it's more
> > complicated than it can seem in the first place).
> Depending on the knowledge of the developer a rough estimation for the
> effort would be 3-4 weeks. 
Yiik :-(  I had dreamed it would be 1 or 2 days 
> Too much for me to start that task now.
Much too much indeed.

Thanks again for your precious input.
Regards, 
Camille


-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



Re: [dev] Re: [dba-dev] solved: DateTime construction from a TIMESTAMP_STRUCT

2010-03-24 Thread Terrence Enger
On Wed, 2010-03-24 at 06:10 -0400, Terrence Enger wrote:

[ lots of stuff which he has now sent to dba-dev, where he should have
sent it in the first place ]

Sorry for the noise.



-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



[dev] Re: [dba-dev] solved: DateTime construction from a TIMESTAMP_STRUCT

2010-03-24 Thread Terrence Enger
On Tue, 2010-03-23 at 14:44 -0400, Terrence Enger wrote:

> This silly question 

Yes, it was silly.  I was confusing two different variables.  Please
accept my apology for the noise on the list.

New morning, fresh pot of coffee.  I hope for better results.

> arises because I am looking at issue 94543
> .
> 
> I observe in my attachement
> 
> that the value
> 1990-03-02 08:30:00.100 
> is being shown as
> 1990-03-02 08:39:54
> I observe further that the fraction of a second comes from
> SQLGetData() as 10,000,000 nanoseconds, and that (1 * 1000)
> modulo 65536 is 59392, and that 59392 centiseconds is the error in the
> displayed value.

I still think that that observation is correct, and I can even point to
OResultSet.cxx line 657.  Going off now to test my google skills on the
definition of TIMESTAMP_STRUCT.fraction.

Cheers,
Terry.



-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org



Re: [dev] Transforming the Hyperlink bar in a websearch toolbar

2010-03-24 Thread Mathias Bauer
MOULIN Camille wrote:

> Hi Mathias, Mathias Bauer a écrit : [...]
>> Where do you see the Hyperlink Bar not behaving like other
>> toolbars?
> 
> A"regular" toolbar has a drop down menu on the right end, allowing
> you to choose the buttons you want to display, you can (un)anchor it,
> move it around, etc. That means also that if it's narrow enough, you
> can stick it to the right of your Standard toolbar.
That's not entirely correct. The configuration menu is shown only for
configurable toolbars and there are "regular" toolbars that are not
configurable also, e.g. toolbars in extensions.

OK, you want to have the hyperlink bar configurable.

> Please have a look at the pictures below to see what I mean
> 
> http://wiki.services.openoffice.org/wiki/User:Camillem/MyDrafts#Before
>  and 
> http://wiki.services.openoffice.org/wiki/User:Camillem/MyDrafts#After
> 
>> I mean, it's indeed a different implementation (because the
>> controls are not independent from each other and so the toolbar
>> itself implements some control logic), but until now I didn't see
>> any difference from a UX point of view.
> 
> Well, my question was also from a developper point of view : I think
> this change would be beneficial to OOo (see
> http://wiki.services.openoffice.org/wiki/User:Camillem/MyDrafts#Web_search_Toolbar
> for more details), but I'm wondering if it's worth the effort.

There are two ways to implement that feature: convert the hyperlink bar
into a "regular toolbar" or extend the SfxChildWindow based
implementations to support toolbars. Probably the latter would be a
waste of time as the code is planned to be replaced. For a "regular
toolbar" all code currently in the hyperlink bar class must be moved
into the controllers - a quite challenging task.

> That's why I was asking how long would it take to implement such a
> change and what level of OOo knowledge would it require (as the
> specificity of the implementation let me suppose it's more
> complicated than it can seem in the first place).
Depending on the knowledge of the developer a rough estimation for the
effort would be 3-4 weeks. Too much for me to start that task now.

Regards,
Mathias



-
To unsubscribe, e-mail: dev-unsubscr...@openoffice.org
For additional commands, e-mail: dev-h...@openoffice.org