Miroslav Šulc created NETBEANS-3687:
---------------------------------------

             Summary: parameters comment formatting has destructive bug when 
the line is too long
                 Key: NETBEANS-3687
                 URL: https://issues.apache.org/jira/browse/NETBEANS-3687
             Project: NetBeans
          Issue Type: Bug
          Components: editor - Formatting & Indentation
    Affects Versions: 11.2, Next
            Reporter: Miroslav Šulc
         Attachments: formatting.zip

here is an example code:

 
{code:java}
package com.fordfrog.ibtws;

import com.fordfrog.ibtws.entities.ContractSpec;
import com.fordfrog.ibtws.impl.entities.ContractSpecImpl;

/**
 * TWS service factory.
 */
public class TWSServiceFactory {

    /**
     * Creates new {@link ContractSpec} instance.
     *
     * @param secType                        {@link ContractSpec#getSecType()}
     * @param symbol                         {@link ContractSpec#getSymbol()}
     * @param currency                       {@link ContractSpec#getCurrency()}
     * @param exchange                       {@link ContractSpec#getExchange()}
     * @param lastTradingDateOrContractMonth {@link 
#getLastTradingDateOrContractMonth()}
     * @param multiplier                     {@link 
ContractSpec#getMultiplier()}
     *
     * @return
     */
    public static ContractSpec createContractSpec(final String secType,
            final String symbol, final String currency, final String exchange,
            final String lastTradingDateOrContractMonth,
            final String multiplier) {
        return new ContractSpecImpl(secType, symbol, currency, exchange,
                lastTradingDateOrContractMonth, multiplier);
    }
}
{code}
after saving the code, the parameter comments change to this:
{code:java}
    /**
     * Creates new {@link ContractSpec} instance.
     *
     * @param secType                        {@link ContractSpec#getSecType()}
     * @param symbol                         {@link ContractSpec#getSymbol()}
     * @param currency                       {@link ContractSpec#getCurrency()}
     * @param exchange                       {@link ContractSpec#getExchange()}
     * @param
     *                                       lastTradingDateOrContractMonth 
{@link #getLastTradingDateOrContractMonth()}
     * @param
     *                                       multiplier                     
{@link ContractSpec#getMultiplier()}
     *
     * @return
     */
{code}
if i later modify the code and resave it, it becomes this:
{code:java}
    /**
     * Creates new {@link ContractSpec} instance.
     *
     * @param secType                        {@link ContractSpec#getSecType()}
     * @param symbol                         {@link ContractSpec#getSymbol()}
     * @param currency                       {@link ContractSpec#getCurrency()}
     * @param exchange                       {@link ContractSpec#getExchange()}
     * @param etLastTradingDateOrContractMonth()}
     * @param ntractSpec#getMultiplier()}
     *
     * @return
     */
{code}
further edits and savings cripple it even more.

i'm attaching exported formatting configuration from netbeans options.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to