Activating an auto-correct without inputting a trailing spac

Discuss the word processor
Post Reply
Dayvid
Posts: 4
Joined: Sun May 24, 2020 3:40 am

Activating an auto-correct without inputting a trailing spac

Post by Dayvid »

I want Auto-Correct to respond to defined "Replace" characters without needing to follow them with a space. Ideally, this would be a setting for each Auto-Correct entry, but a global option would be acceptable at this point. For example, I would like Open Office to automatically change any occurrence of "++" (two plus signs) to ":" (a colon).

Here is my situation, and if there is another approach that would accomplish the end, I am open to that. In my work, I key in a lot of time values in HH:MM:SS format, or some variation of that. There are other items where I could use this functionality also, but for here I will limit my description to this. A solution to this will likely apply to any of the others as well.

The numeric portion of my values is easily input with the number pad. However, when I come to the colons, I (by default) need to take my hand from the number pad and press [Shift]+[:], then return my hand to the number pad, which is rather inefficient. I could use the QWERTY portion of the keyboard, which would avoid moving my hand. But that would require keeping both hands on the keyboard, and I typically input these values with one hand on the number pad while marking my place on a paper document with the other, which is sort of what the number pad is for.

Some of the applications that I use allow me to customize their version of what Open Office calls Auto-Correct such that I can simply hit the plus key twice on the number pad (or whatever other key sequence I choose), and it inserts the colon, which is pretty handy. However, I have Open Office configured for that in Auto-Correct, and as far as I can tell, Open Office will not execute the Auto-Correct until it encounters a trailing space, which makes sense in many situations, but not here.

In my situation, I don't want a trialing space, so not only do I have to type a character that also requires moving my hand from the number pad like typing the colon does (or using the other hand, which as previously mentioned is typically marking my location on some paper document from I am reading the data), after I press the space bar to trigger the Auto-correct, I then need to delete the unwanted space. It would require hitting [+][+][space][backspace], which is more cumbersome that typing the colon directly, except for maybe that it does not require a key combination. When inputting a long string of time values, about every third character is a colon, so having a colon key on the number pad would be sweet, but there isn't one on my keyboard.

I did read something about an option in Open Office for having the trailing space not inserted into the text, but that seemed to be applicable only to Word-Completion, which is another animal. I don't think Word-Completion would be relevant to what I want it to do.

If Open office has a setting that tells Auto-Correct "Wait for a trailing space" or "Don't", that would fix this for me. Or if there is some way to input a "Replace" string ("*++*" for example) that tells Auto-Correct not to wait for a space for this string, that would suite. I did see in my research some examples of special Replace strings in Open Office that include some control-type characters which supported included spaces (for example, change "Sendt o" to "Send to" ), although in my testing, that seems to work fine without any special characters in the string, so maybe I was missing the point there. Nevertheless, I have searched all the Help, looked through this forum, and searched the internet, but I have not found this matter even addressed anywhere, whether Open Office does it or not.

Anybody have any insight?
Last edited by MrProgrammer on Fri Jun 05, 2020 9:54 pm, edited 1 time in total.
Reason: Moved topic from Beginners forum to Writer
OpenOffice 4.1.3 on Windows 7 Home Premium
User avatar
Zizi64
Volunteer
Posts: 11358
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: Activating an auto-correct without inputting a trailing

Post by Zizi64 »

I want Auto-Correct to respond to defined "Replace" characters without needing to follow them with a space. Ideally, this would be a setting for each Auto-Correct entry, but a global option would be acceptable at this point. For example, I would like Open Office to automatically change any occurrence of "++" (two plus signs) to ":" (a colon).

...

If Open office has a setting that tells Auto-Correct "Wait for a trailing space" or "Don't", that would fix this for me.
The AuroCorrect function of the LibreOffice can replace some characters inside a word. Not needed any trailing white space.
Just use the next format in the Replace edit box:

Code: Select all

:++:
and use

Code: Select all

:
in the With edit box.

Note:
The AutoCorrect function was developed for substitute some characters during you type-in the text.
After typing you can use the Search & Relplace function to achieve this task.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Dayvid
Posts: 4
Joined: Sun May 24, 2020 3:40 am

Re: Activating an auto-correct without inputting a trailing

Post by Dayvid »

Hmm. I put ":++:" (colon, plus, plus, colon) in the Replace field and only a colon in the With field. Nothing happens at all except when I type ":++:" followed by a space, I get the colon. Those characters don't seem to be treated as anything other than normal characters to find in my typing.

I am aware that I could use search and replace to modify it after the fact, but that is a work-around that isn't particularly appealing. My data would look pretty bazaar until I did that secondary edit. And if I forgot to do that or got interrupted and the data traveled downstream the way I keyed it in, that would cause some consternation for other users.
OpenOffice 4.1.3 on Windows 7 Home Premium
Dayvid
Posts: 4
Joined: Sun May 24, 2020 3:40 am

Re: Activating an auto-correct without inputting a trailing

Post by Dayvid »

Let me add for clarity that typing only the plus, plus leaves me with simply two plus signs. I didn't specifically address that in my original reply, but only alluded to it. It is as though there is no Auto-Correct string applicable to those two characters. It seems to only look for all four characters together from that string I put in the Replace field.
OpenOffice 4.1.3 on Windows 7 Home Premium
User avatar
Zizi64
Volunteer
Posts: 11358
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: Activating an auto-correct without inputting a trailing

Post by Zizi64 »

Hmm. I put ":++:" (colon, plus, plus, colon) in the Replace field and only a colon in the With field. Nothing happens at all except when I type ":++:" followed by a space, I get the colon. Those characters don't seem to be treated as anything other than normal characters to find in my typing.

I am aware that I could use search and replace to modify it after the fact, but that is a work-around that isn't particularly appealing. My data would look pretty bazaar until I did that secondary edit. And if I forgot to do that or got interrupted and the data traveled downstream the way I keyed it in, that would cause some consternation for other users.
___________________________________________________
OpenOffice 4.1.3 on Windows 7 Home Premium
This function exists in the LibreOfice only.
https://www.libreoffice.org/
It will replace the typed-in plusplus characters inside a word "abcdefg++hij" after typing the ++ characters, and then you can continue the typing of the string without trailing spaces.
The result will be:
"abcdefg:hij"

Only the setting of the AutoCorrect function needs the control chararacters
:++:
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Bill
Volunteer
Posts: 8932
Joined: Sat Nov 24, 2007 6:48 am

Re: Activating an auto-correct without inputting a trailing

Post by Bill »

Zizi64 wrote:It will replace the typed-in plusplus characters inside a word "abcdefg++hij" after typing the ++ characters, and then you can continue the typing of the string without trailing spaces.
The result will be:
"abcdefg:hij"
It doesn't work like that for me in LO 6.3.6.2 and LO 6.4.3.2. In both cases I had to type "abcdefg:++:hij" to get "abcdefg:hij". Typing "abcdefg++hij" remained "abcdefg++hij".

@Dayvid: You can set up a "hotstring" in AutoHotKey to replace the abbreviation "++" with ":". Hotstrings should work in all applications.
AOO 4.1.14 on Ubuntu MATE 22.04
User avatar
Zizi64
Volunteer
Posts: 11358
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: Activating an auto-correct without inputting a trailing

Post by Zizi64 »

It doesn't work like that for me in LO 6.3.6.2 and LO 6.4.3.2. In both cases I had to type "abcdefg:++:hij" to get "abcdefg:hij". Typing "abcdefg++hij" remained "abcdefg++hij".
I tested it in my LO 6.2.8 first. That works as I described it.

Now, I tested it with the portable LO 6.4.3, and it works as you described it. I do not know if it is a bug, or some changed conception, or (maybe) it need some extra settings in the newer versions.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
User avatar
Hagar Delest
Moderator
Posts: 32655
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Activating an auto-correct without inputting a trailing

Post by Hagar Delest »

If it is acceptable for you to have the second hand at work, you can set an Auto Text entry with the mere colon and give it the + shortcut.
Type a colon, select it, then menu Edit>AutoText (F3), give it a name, type + for the shortcut, then on the right, AutoText button -> New.
Next time you enter a time, after typing a (single) +, hit F3 with your other hand.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: Activating an auto-correct without inputting a trailing

Post by John_Ha »

See AutoHotKey which works in any application. It's how I write ...

Showing that a problem has been solved helps others searching so, if your problem is now solved, please view your first post in this thread and click the Edit button (top right in the post) and add [Solved] in front of the subject.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
jrkrideau
Volunteer
Posts: 3816
Joined: Sun Dec 30, 2007 10:00 pm
Location: Kingston Ontario Canada

Re: Activating an auto-correct without inputting a trailing

Post by jrkrideau »

Zizi64 wrote: Now, I tested it with the portable LO 6.4.3, and it works as you described it. I do not know if it is a bug, or some changed conception, or (maybe) it need some extra settings in the newer versions.
I have the same problew with 6.4.3.2; it looks like a change.
LibreOffice 7.3.7. 2; Ubuntu 22.04
Dayvid
Posts: 4
Joined: Sun May 24, 2020 3:40 am

Re: Activating an auto-correct without inputting a trailing

Post by Dayvid »

Thanks for the responses and the ideas, folks. I browsed them just now, but I won't have time to test tings out for a couple of days. I'll respond again once I do.
OpenOffice 4.1.3 on Windows 7 Home Premium
Post Reply