writer vs calc behaviour in LO 6.0.1.1

classic Classic list List threaded Threaded
5 messages Options
Dave Stevens Dave Stevens
Reply | Threaded
Open this post in threaded view
|

writer vs calc behaviour in LO 6.0.1.1

I'm using the version in the subject line on Linux Mint. In calc if I
insert the date using the insert menu and the date option I get a cell
with today's date, formatted comprehensibly. If I do the same thing in
Writer I can't, the option isn't there. I must (as far as I know)
choose field then date. That gives me text that looks like "Date
(fixed)" which is not what I want. I can do a print preview and see
that it will render as one might wish but that's not what I want. I
really want to be able to simply insert today's date as a character
string.

I think the behaviour I'm seeing breaks wysiwyg.

Can anyone tell me a simple way to insert the data as characters rather
than a field?

TIA

Dave

--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Brian Barker Brian Barker
Reply | Threaded
Open this post in threaded view
|

Re: writer vs calc behaviour in LO 6.0.1.1

At 11:03 24/02/2018 -0800, Dave Stevens wrote:
>I'm using the version in the subject line on Linux Mint. In calc if
>I insert the date using the insert menu and the date option I get a
>cell with today's date, formatted comprehensibly.

I'm not sure what you mean here. If you are using the =TODAY() or
=NOW() functions, what you have is not today's date but the current
date whenever your spreadsheet is reopened.

>If I do the same thing in Writer I can't, the option isn't there. I
>must (as far as I know) choose field then date. That gives me text
>that looks like "Date (fixed)" which is not what I want. I can do a
>print preview and see
>that it will render as one might wish but that's not what I want. I
>really want to be able to simply insert today's date as a character string.

I think your only problem here is that you have fields set to show
the field name instead of their value. You can toggle this display at
View | Field Names (or Ctrl+F9). Then you will see the date value as
text in the editing display as well as in Page Preview and actual printout.

>Can anyone tell me a simple way to insert the data as characters
>rather than a field?

o Copy the field.
o Paste it back over itself, but using Edit | Paste Special... (or
right-click | Paste Special... or Ctrl+Shift+V) and selecting
"Unformatted text" in the Paste Special dialogue.

Er, or just type the date: the default format is only eight
characters (in my locale).

>I think the behaviour I'm seeing breaks wysiwyg.

I hope so. Wysiwyg was always a bad idea: what you need in the
editing display is a clear indication of the structure of your
document, not necessarily its appearance. That way, you can see and
have some control over what will happen when it is displayed on
another system or you (or others) make any change.

I trust this helps.

Brian Barker


--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Jean-Francois Nifenecker Jean-Francois Nifenecker
Reply | Threaded
Open this post in threaded view
|

Re: writer vs calc behaviour in LO 6.0.1.1

In reply to this post by Dave Stevens
Hi,

Le 24/02/2018 à 20:03, Dave Stevens a écrit :

> I'm using the version in the subject line on Linux Mint. In calc if I
> insert the date using the insert menu and the date option I get a cell
> with today's date, formatted comprehensibly. If I do the same thing in
> Writer I can't, the option isn't there. I must (as far as I know)
> choose field then date. That gives me text that looks like "Date
> (fixed)" which is not what I want. I can do a print preview and see
> that it will render as one might wish but that's not what I want. I
> really want to be able to simply insert today's date as a character
> string.
>
> I think the behaviour I'm seeing breaks wysiwyg.
>
> Can anyone tell me a simple way to insert the data as characters rather
> than a field?

not exactly what you're looking for, but here we go: as the shortcut to
get a date in a Calc cell is Ctrl + ; you might duplicate that behaviour
in Writer.

Here's how: create a new shortcut that does that, too.

In Writer:
1. Go to Tools > Customize
2. Select the Keyboard tab
3. Check that Writer is the option selected (top right radiobutton)
4. In the Shortcut keys panel, select the Ctrl + ; shortcut
5. Select :
category: Insert
function: Date
6. Click Modify
The selected shortcut appears in the Keys panel
7. OK

 From now on, hitting Ctrl + ; in Writer inserts a date field (yes, sorry).

Now, if you want to actually insert a string, you'll need a macro :

1. Add the following macro to MyMacros & Dialogs.Standard.Module1 (for
instance)

8< --------------------------------------------
Sub InsertTodaysDate()

        Dim oVCur As Object 'visible cursor
        Dim oWCur As Object 'writing cursor
        Dim l_Str As String

        'get the date
        l_Str = CStr(Date)
        'get the view cursor
        oVCur = ThisComponent.CurrentController.ViewCursor
        'set a writing cursor at the visible cursor place
        oWCur = oVCur.Text.CreateTextCursorByRange(oVCur)
        'write...
        oWCur.String = l_Str
       
End Sub 'InsertTodaysDate
------------------------------------------- >8

2. Set the shortcut (as shown above) to the said macro, with
category: select LibreOffice Macros > MyMacros > (your macro library) >
(your macro module)
function: your macro name


Now Ctrl + ; inserts todays date at the cursor position.


HTH,
--
Jean-Francois Nifenecker, Bordeaux


--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Alex McMurchy Alex McMurchy
Reply | Threaded
Open this post in threaded view
|

Re: writer vs calc behaviour in LO 6.0.1.1

In reply to this post by Dave Stevens
On 24/02/18 19:03, Dave Stevens wrote:
> Can anyone tell me a simple way to insert the data as characters rather
> than a field?


Maybe use this process.

 1. Insert the field date (fixed) in the format required
 2. Select the inserted field date (fixed)
 3. Cut the selected data
 4. Paste (unformatted)

if this is too cumbersome code something as a macro and link it to the
tool bar.


Alex


--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted
Dave Stevens Dave Stevens
Reply | Threaded
Open this post in threaded view
|

Re: writer vs calc behaviour in LO 6.0.1.1

In reply to this post by Brian Barker
On Sat, 24 Feb 2018 19:50:08 +0000
Brian Barker <[hidden email]> wrote:

> At 11:03 24/02/2018 -0800, Dave Stevens wrote:
> >I'm using the version in the subject line on Linux Mint. In calc if
> >I insert the date using the insert menu and the date option I get a
> >cell with today's date, formatted comprehensibly.  
>
> I'm not sure what you mean here. If you are using the =TODAY() or
> =NOW() functions, what you have is not today's date but the current
> date whenever your spreadsheet is reopened.

I'm not using a function. In calc I pull down the insert menu and click
on date. Then the cell contents are text characters with today's
date. Not a function. This is what I'd like to be able to do in Writer.

Thanks to those who suggested workarounds.

Dave

>
> >If I do the same thing in Writer I can't, the option isn't there. I
> >must (as far as I know) choose field then date. That gives me text
> >that looks like "Date (fixed)" which is not what I want. I can do a
> >print preview and see
> >that it will render as one might wish but that's not what I want. I
> >really want to be able to simply insert today's date as a character
> >string.  
>
> I think your only problem here is that you have fields set to show
> the field name instead of their value. You can toggle this display at
> View | Field Names (or Ctrl+F9). Then you will see the date value as
> text in the editing display as well as in Page Preview and actual
> printout.
>
> >Can anyone tell me a simple way to insert the data as characters
> >rather than a field?  
>
> o Copy the field.
> o Paste it back over itself, but using Edit | Paste Special... (or
> right-click | Paste Special... or Ctrl+Shift+V) and selecting
> "Unformatted text" in the Paste Special dialogue.
>
> Er, or just type the date: the default format is only eight
> characters (in my locale).
>
> >I think the behaviour I'm seeing breaks wysiwyg.  
>
> I hope so. Wysiwyg was always a bad idea: what you need in the
> editing display is a clear indication of the structure of your
> document, not necessarily its appearance. That way, you can see and
> have some control over what will happen when it is displayed on
> another system or you (or others) make any change.
>
> I trust this helps.
>
> Brian Barker
>
>


--
To unsubscribe e-mail to: [hidden email]
Problems? https://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: https://wiki.documentfoundation.org/Netiquette
List archive: https://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted