Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Class help text wrapping

Subject: Class help text wrapping

From: Etienne

Date: 28 Jul, 2010 12:10:06

Message: 1 of 4

Hi Folks

I am trying to document some classes I have created, and am strugling with the format of the help text. I would like to add enough comments for each property, but it seems that when the comment stretches over more than one line, it is cut off, so you have to place it in one line. Is there a way to avoid having to do this, or rather, how can use comments on multiple lines.

Regards

Etienne

Subject: Class help text wrapping

From: Maxx Chatsko

Date: 28 Jul, 2010 12:29:06

Message: 2 of 4

"Etienne" <etienne.coetzee@airbus.com> wrote in message <i2p6mu$a0e$1@fred.mathworks.com>...
> Hi Folks
>
> I am trying to document some classes I have created, and am strugling with the format of the help text. I would like to add enough comments for each property, but it seems that when the comment stretches over more than one line, it is cut off, so you have to place it in one line. Is there a way to avoid having to do this, or rather, how can use comments on multiple lines.
>
> Regards
>
> Etienne

Certain dialog boxes wrap automatically (questdlg) and others don't (). Example from my code:
questdlg({' The data on file shows that the pure component you'
                 'have selected was extremely fluorescent during FCI'
                 'acquisitions. Are you sure you want to proceed with'
                 'processing this data?'},'High Fluorescence Warning','Yes',...
                 'No','Info','No');

This has buttons obviously, but you can see how the wrapping is automatic. Another way around this is to type char(10) at the end of each line for dialogs that do not wrap - it is the character signal for a new line, equivelent to hitting 'Enter'.
     Maxx
    

Subject: Class help text wrapping

From: Maxx Chatsko

Date: 28 Jul, 2010 12:57:05

Message: 3 of 4

  Great example for ones that don't wrap huh? haha. errordlg does not wrap, unless you force it with char(10)...

Subject: Class help text wrapping

From: Steven_Lord

Date: 28 Jul, 2010 13:17:06

Message: 4 of 4



"Etienne" <etienne.coetzee@airbus.com> wrote in message
news:i2p6mu$a0e$1@fred.mathworks.com...
> Hi Folks
>
> I am trying to document some classes I have created, and am strugling with
> the format of the help text. I would like to add enough comments for each
> property, but it seems that when the comment stretches over more than one
> line, it is cut off, so you have to place it in one line. Is there a way
> to avoid having to do this, or rather, how can use comments on multiple
> lines.

You can disable autowrapping:

http://www.mathworks.com/access/helpdesk/help/techdoc/matlab_env/brxijcd.html#brxijj0-53

or, if you want to keep autowrapping on, you can manually undo the
autowrapping by moving to the beginning of the line onto which the comment
autowrapped and pressing Delete.

I'm not _certain_ if there's anything different about property help text,
but for a function the help text can span multiple rows, up until the first
row that does not begin with a single %.

--
Steve Lord
slord@mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ
To contact Technical Support use the Contact Us link on
http://www.mathworks.com

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us