[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User thorstenziehm changed the following: What|Old value |New value Target milestone|OOo 3.3 |OOo 3.x --- Additional comments from thorstenzi...@openoffice.org Thu Sep 23 09:46:51 + 2010 --- OOo 3.3 is in showstopper-mode. This issue is too old to be a stopper for the current release. I change the target to OOo 3.x. Please change the target accordingly when a fix is near to be integrated into a code line. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: issues-unsubscr...@sw.openoffice.org For additional commands, e-mail: issues-h...@sw.openoffice.org - To unsubscribe, e-mail: allbugs-unsubscr...@openoffice.org For additional commands, e-mail: allbugs-h...@openoffice.org
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User jsk changed the following: What|Old value |New value OS/Version|Windows XP|All Target milestone|OOo 3.2 |OOo 3.3 --- Additional comments from j...@openoffice.org Thu Oct 1 11:22:22 + 2009 --- This issue has target 3.2 - do we have any progress here? I assume no and set it to 3.3 for now. The sample was intended to show that Yes, you can use python, AFAIK noone ever intended to deliver a fully functional piece of code, the best way to do this is via extensions. IIRC such an extension exists already... - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: issues-unsubscr...@sw.openoffice.org For additional commands, e-mail: issues-h...@sw.openoffice.org - To unsubscribe, e-mail: allbugs-unsubscr...@openoffice.org For additional commands, e-mail: allbugs-h...@openoffice.org
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User mh changed the following: What|Old value |New value Target milestone|OOo 3.1 |OOo 3.2 - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: issues-unsubscr...@sw.openoffice.org For additional commands, e-mail: issues-h...@sw.openoffice.org - To unsubscribe, e-mail: allbugs-unsubscr...@openoffice.org For additional commands, e-mail: allbugs-h...@openoffice.org
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User jza changed the following: What|Old value |New value CC|'hr,jbu,jza,laurentgodard,|'hr,jbu,jza,laurentgodard, |mba,mh' |louis,mba,mh' --- Additional comments from [EMAIL PROTECTED] Tue Nov 25 03:27:01 + 2008 --- Added Louis to it. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User mh changed the following: What|Old value |New value Target milestone|OOo 3.0 |OOo 3.1 --- Additional comments from [EMAIL PROTECTED] Mon Sep 22 08:09:12 + 2008 --- move target to 3.1 - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User jza changed the following: What|Old value |New value CC|'hr,jza,laurentgodard,mba,|'hr,jbu,jza,laurentgodard, |mh' |mba,mh' --- Additional comments from [EMAIL PROTECTED] Fri Jun 6 15:41:34 + 2008 --- I think I submit the CVS branch: http://framework.openoffice.org/source/browse/framework/scripting/examples/ python/ the owner has 'hr' Joerg B. might/could be the mantainer, I am still not sure why he isn't on the CC distribution. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 --- Additional comments from [EMAIL PROTECTED] Fri Jun 6 16:34:44 + 2008 --- ah ok I see, so i have a question, if someone else want to patch that file, the code should be submited to the original owner. I know Joerg is very active, but what if the owner was long gone from the project? - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 --- Additional comments from [EMAIL PROTECTED] Fri Jun 6 16:44:04 + 2008 --- The project lead of the affected project can be considered the default owner. If in doubt RE (hjs,hr,rt etc) can help you or program management (mh). Or just ask on IRC. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User mba changed the following: What|Old value |New value Assigned to|mba |ab --- Additional comments from [EMAIL PROTECTED] Thu Jun 5 14:13:04 + 2008 --- Finally I found out where the file is located: it's an example in the scripting project: scripting/examples/python/Capitalise.py - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User jsk changed the following: What|Old value |New value Assigned to|jsk |mba Ever confirmed| |1 Status|UNCONFIRMED |NEW --- Additional comments from [EMAIL PROTECTED] Tue Apr 15 09:24:36 + 2008 --- I'm QA and as such i can never be owner of a patch. -MBA: I have no idea whether JBU still works on this, so if you like the patch, put it in :-) - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 --- Additional comments from [EMAIL PROTECTED] Tue Apr 15 09:13:11 + 2008 --- Jörg, what's the problem? You are currently blocking this issue. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User mba changed the following: What|Old value |New value CC|'hr,jza,laurentgodard,mba'|'hr,jza,laurentgodard,mba, | |mh' --- Additional comments from [EMAIL PROTECTED] Tue Apr 15 12:22:27 + 2008 --- Thanks, Jörg. I think we have to figure out who maintains this code nowadays. The only thing I know about Python is Monty Python's Flying Circus. :-) Martin, any idea in which module of the source tree this macro can be found? - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User mba changed the following: What|Old value |New value CC|'hr,jza,laurentgodard'|'hr,jza,laurentgodard,mba' Target milestone|--- |OOo 3.0 --- Additional comments from [EMAIL PROTECTED] Tue Jan 29 14:01:52 + 2008 --- Jörg, are you the right owner for this patch? If yes: please take care of it. If not: please reassign it. As patches need a target I set it to the next possible. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User laurentgodard changed the following: What|Old value |New value CC|'hr,jza' |'hr,jza,laurentgodard' - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User mru changed the following: What|Old value |New value Assigned to|mru |jsk --- Additional comments from [EMAIL PROTECTED] Tue Oct 23 07:48:48 + 2007 --- Reassigned to JSK. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 Issue #|82861 Summary|Python: Capitalize macro Component|Word processor Version|OOo 2.3 Platform|All URL| OS/Version|All Status|UNCONFIRMED Status whiteboard| Keywords| Resolution| Issue type|PATCH Priority|P3 Subcomponent|programming Assigned to|mru Reported by|the_gray_cardinal --- Additional comments from [EMAIL PROTECTED] Mon Oct 22 17:57:41 + 2007 --- Macro Capitalise.py is distributed with OpenOffice v2.3. But I don't like it much because of the following reasons: 1. It doesn't work with the last word in a file, when there isn't any text or line feed after this word. 2. If you work with a word that has caret within it (not with a selected piece of text), for some reason Capitalise.py selects this word after processing. 3. If you deal with some non-adjacent selected pieces of text inside a document, a runtime exception occurs. 4. If you deal with a word that contains the caret and stands at the end of a line, after which there is a blank line, Capitalise.py adds another blank line. Here is my version of the Capitalise.py, free of the above peculiarities: === # copyleft © The gray Cardinal, Russia, http://script-coding.info/ def CapitalizeString(theString): # Capitalize function if (not theString or len(theString) == 0): return if theString[0].isupper() and len(theString) = 2 and theString[1].isupper (): newString = theString[0:1].upper() + theString[1:].lower() elif theString[0].isupper(): newString = theString.lower() else: newString = theString.upper() import re newString = re.sub('\n', '', newString) return newString def Capitalize(dummy = ''): ''' Macro for Writer. Changes the case of the selected pieces of text or the word with the caret within it. ''' xController = XSCRIPTCONTEXT.getDocument().getCurrentController() # current selection xIndexAccess = xController.getSelection() # number of selected pieces of text count = xIndexAccess.getCount() if count == 1 and len(xIndexAccess.getByIndex(0).getString()) == 0: # No selection. Process the word with the caret within it. xTextRange = xIndexAccess.getByIndex(0) xWordCursor = xTextRange.getText().createTextCursorByRange(xTextRange) if not xWordCursor.isStartOfWord(): xWordCursor.gotoStartOfWord(False) xWordCursor.gotoEndOfWord(True) theString = xWordCursor.getString() # processing of the text newString = CapitalizeString(theString) # replace the text by the processed text xWordCursor.setString(newString) else: # Selection occurred. Now process all the selected pieces of text. i = 0 while i count: # selected piece of text xTextRange = xIndexAccess.getByIndex(i) # text of selected piece of text theString = xTextRange.getString() if len(theString) 0: # process the text newString = CapitalizeString(theString) # replace the text by the processed text xTextRange.setString(newString) # selection xController.select(xTextRange) # If some non-adjacent pieces of text were selected (by Ctrl), # only the selection of the last piece of text will be restored. # Unfortunately, there is no way to restore selection of all the pieces of text. i += 1 return None g_exportedScripts = Capitalize, - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User the_gray_cardinal changed the following: What|Old value |New value OS/Version|All |Windows XP - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 --- Additional comments from [EMAIL PROTECTED] Mon Oct 22 20:41:59 + 2007 --- Created an attachment (id=49080) Improved Capitsalise sample for Python scripts. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User jza changed the following: What|Old value |New value CC|''|'jza' --- Additional comments from [EMAIL PROTECTED] Mon Oct 22 20:43:52 + 2007 --- Succesfully test it on linux. Please re-assign to Component: Framework and subcomponent: scripting Originally submited by CPH at: http://www.openoffice.org/issues/show_bug.cgi?id=32721 - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 --- Additional comments from [EMAIL PROTECTED] Mon Oct 22 20:50:49 + 2007 --- CVS Banch: http://framework.openoffice.org/source/browse/framework/scripting/examples/python/Capitalise.py?rev=1.2view=log - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]
[sw-issues] [Issue 82861] Python: Capitalize macro
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=82861 User jza changed the following: What|Old value |New value CC|'jza' |'hr,jza' --- Additional comments from [EMAIL PROTECTED] Mon Oct 22 20:51:44 + 2007 --- Forwaded to branch mantainer. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - 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]