Re: [dev] Styles not updating from linked template

2006-03-22 Thread Laurent Godard

Hi Mathias


This strange looking macro will set an internal switch in the document
meta data that enables the template update procedure.
BTW: the same macro will re-enable the update procedure in case you have
switched it off by answering the question do you want to update your
styles with No.



yes it is strange :-)
some magics behind ;-)


You can execute this macro on every document if you want (e.g. by
assigning it to the OnLoad event on application level), if the
document is not based on a template it will not be modified by this macro.



Do you think an addon would be valuable ?
With a macro looping over all opened documents for example
(the OnLMoad event is not applicable in this case unless chosen by user)

Laurent

--
Laurent Godard [EMAIL PROTECTED] - Ingénierie OpenOffice.org
Indesko  http://www.indesko.com
Nuxeo CPS  http://www.nuxeo.com - http://www.cps-project.org
Livre Programmation OpenOffice.org, Eyrolles 2004

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[dev] Client Side Code Help

2006-03-22 Thread Kris Mele
Hello,
   I was wondering if someone could point me in the right direction with some 
code I am trying to migrate over from MSWord to OpenOffice?  I have posted on 
the forum, but no one has been able to help as of yet.  What I am trying to 
replicate is creating mailing labels on the user's computer via the Internet.  
For example, they would like to send a mailing out to their active members.  On 
the client side code with MSWord, I pass a recordset and build each label based 
upon the layout forced in the code.  This is done with vbscript.  With vbscript 
and some code I have been able to find, I can pop the avery 5160 template, but 
cannot figure out how to populate the labels.  Each label needs to be a 
different person, and there will more than likely be more than one page.  If 
you are interested in the MS version, check out this link:
http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:80/support/kb/articles/q285/1/76.aspNoWebContent=1
I really appreciate any help you all might be able to give me.  I have been 
banging my head against the cube forever.  
Thanks,
Kris

[dev] To OpenOffice Developer:

2006-03-22 Thread 紫贏



To OpenOffice Developer:I have found a bug in 
Draw of OpenOffice and it's about exporting the file to swf 
formation.The bug is as following:When exporting the 
file to swf formation, the file will automatically adjust its width to 720 pixel 
along with a constrain proportional length; 

no matter what pixel I have set up in advance.I 
hereby attach 3 examples to illustrate my question.Could this bug 
be solved?If it could, how should I fix my programming language in 
Visual Basic?I made the followings programming 
languages.


'==
Sub wmf2swf(srcF, outSWF)'ooffice Service 
Set objServiceManager = CreateObject("com.sun.star.ServiceManager")'Create 
the Desktop Set StarDesktop = 
objServiceManager.createInstance("com.sun.star.frame.Desktop")'建立 
Draw Dim OpenParam(1) As Object '文件參數 Set 
OpenParam(0) = MakePropertyValue("Hidden", True) ' 隱藏 Set 
oDrawDoc = StarDesktop.loadComponentFromURL("private:factory/sdraw", "_blank", 
0, OpenParam())'抓取 第一頁 Set oDrawPage = 
oDrawDoc.getDrawPages().getByIndex(0)'建立 圖片Obj Set oShape = 
oDrawDoc.createInstance("com.sun.star.drawing.GraphicObjectShape")'匯入 
wmf oShape.GraphicURL = ConvertToUrl(srcF) Call 
oDrawPage.Add(oShape) '加入頁面 oShape.Size = 
oShape.Graphic.Size100thMM '還原尺寸 'MsgBox 
oShape.Size.Width 'MsgBox oShape.Size.Height 
oDrawPage.Width = oShape.Size.Width oDrawPage.Height = 
oShape.Size.Height ' Dim optionsfiltre(1) 'As 
New com.sun.star.beans.PropertyValue ' Set optionsfiltre(0) = 
objServiceManager.Bridge_GetStruct("com.sun.star.beans.PropertyValue") 
' Set optionsfiltre(1) = 
objServiceManager.Bridge_GetStruct("com.sun.star.beans.PropertyValue") 
 ' optionsfiltre(0).Name = "PixelWidth" ' 
optionsfiltre(0).Value = oDrawPage.Width ' optionsfiltre(1).Name 
= "PixelHeight" ' optionsfiltre(1).Value = 
oDrawPage.Height

 '輸出 Dim SaveParam(1) As 
Object '文件參數 Set SaveParam(0) = MakePropertyValue("FilterName", 
"draw_flash_Export") '轉出 flash 格式 'Set SaveParam(1) = 
MakePropertyValue("FilterData", optionsfiltre)

  Dim sFileUrl 
sFileUrl = ConvertToUrl(outSWF) ' 輸出檔名 ' Call MsgBox(sFileUrl, 
vbOKOnly) Call oDrawDoc.storeToURL(sFileUrl, SaveParam()) 
'執行 Call oDrawDoc.Close(True) '關閉文件 '釋放 
資源 Set sFileUrl = Nothing Erase 
SaveParam Set oShape = Nothing Set 
oDrawPage = Nothing Set oDrawDoc = 
Nothing Erase OpenParam Set 
StarDesktop = Nothing Set objServiceManager = 
Nothing

End Sub

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: [dev] The Crash Reporter

2006-03-22 Thread Gregor Hartmann
Hi,

just one more comment...

Am 21.03.06, 11:23:07, schrieb Caolan McNamara [EMAIL PROTECTED] zum 
Thema [dev] The Crash Reporter:


[...]

 Crash reports submitted to the normal Sun crash reporter database
 are not visible to non-Sun developers. Especially during the development
 stage of a distro when e.g. new releases of compilers, or other base
 technology are being used, distro developers really want to get OOo
 crash reports directly to them, or to their distribution, which are
 likely to be specific to them alone. There doesn't seem to be a point in
 spamming the normal bug database with spurious non-OOo problems, at
 least in the before ready to ship stage.

Its even worse. To be able to get also the sourcecode lines of the stacks 
sun keeps the original debug information for the binaries delivered. Sun 
then works on the 'enriched' stacks only. So a crash report which is sent 
in from a build form a non Sun source cannot be used at all since the 
debug information is missing. So such crash reports are always spam which 
has to be sorted out.
So That's why “there are a few hoops to be jumped through if an outside 
developer want to enable the crash reporter.”

[...]

Gregor

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [dev] The Crash Reporter

2006-03-22 Thread Caolan McNamara
On Wed, 2006-03-22 at 11:12 +, Gregor Hartmann wrote:
 Its even worse. To be able to get also the sourcecode lines of the stacks 
 sun keeps the original debug information for the binaries delivered. Sun 
 then works on the 'enriched' stacks only. So a crash report which is sent 
 in from a build form a non Sun source cannot be used at all since the 
 debug information is missing. So such crash reports are always spam which 
 has to be sorted out.
 So That's why “there are a few hoops to be jumped through if an outside 
 developer want to enable the crash reporter.”

Yeah, makes sense of course. In our own case RedHat keeps and provides
debuginfo rpms of extracted debugging data, so theoretically I guess we
would be able to use the same or similiar process to make sense of crash
reporter data from our stripped builds.

Is the stripped stacktrace - stacktrace with symbols code used by
the Sun process freely available in any form ?

C.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [dev] Client Side Code Help

2006-03-22 Thread Tom Schindl
Hi,

you are talking about OO-API-Usage so dev@api.openoffice.org might be a
better place to ask. Even checkout the Dev-Guide for information about
the OpenOffice-UNO-API.

http://api.openoffice.org/DevelopersGuide/DevelopersGuide.html

Tom

Kris Mele wrote:
 Hello,
I was wondering if someone could point me in the right direction with some 
 code I am trying to migrate over from MSWord to OpenOffice?  I have posted on 
 the forum, but no one has been able to help as of yet.  What I am trying to 
 replicate is creating mailing labels on the user's computer via the Internet. 
  For example, they would like to send a mailing out to their active members.  
 On the client side code with MSWord, I pass a recordset and build each label 
 based upon the layout forced in the code.  This is done with vbscript.  With 
 vbscript and some code I have been able to find, I can pop the avery 5160 
 template, but cannot figure out how to populate the labels.  Each label needs 
 to be a different person, and there will more than likely be more than one 
 page.  If you are interested in the MS version, check out this link:
 http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:80/support/kb/articles/q285/1/76.aspNoWebContent=1
 I really appreciate any help you all might be able to give me.  I have been 
 banging my head against the cube forever.  
 Thanks,
 Kris



Re: [dev] To OpenOffice Developer:

2006-03-22 Thread Tom Schindl
If that's really a bug file it to to issue-zilla.

Tom


Re: [dev] Using the 'shell' command in OOo 2.0.2

2006-03-22 Thread Gerrit Jasper

Tom Schindl wrote:


Ross Johnson wrote:
 


On Tue, 2006-03-21 at 01:42 +0100, Gerrit Jasper wrote:

   


Gentlemen/ladies,
 


I'm not sure that I completely understand the 'curl part is skipped'
part of your description, but ...

Have you checked the environment that OOo executes the script in? I see
that the soffice script modifies and exports LD_LIBRARY_PATH and PATH by
adding locations to the head of the list, so a conflicting library and
utility name may change behaviour somehow.
   



Sounds reasonable because I think curl is part of OO because in 2.0.2
there's been a security fix for libcurl.

http://qa.openoffice.org/issues/show_bug.cgi?id=59032
http://www.hardened-php.net/advisory_242005.109.html

Tom
 



I was not aware of any relation of OOo with curl.
Thanks a lot

Sincerely,

Gerrit Jasper

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[dev] byteswap

2006-03-22 Thread Michael Leibowitz
Is there a nice, portable way to do byteswapping already present in the
code?  I am looking for something that provides the same sort of
functionality of byteswap.h on glibc.  Surely, there is a this sort of
thing buried in some helper/library/abstraction.  ;-)


-- 
Michael Leibowitz [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]