How to write custom eclipse formatter for a custom file type (text) - eclipse

I'd like to write an eclipse formatter for a custom file type (text based). The goal is to format tabular text data like Fitnesse does, for example:
|column1 | column 2 |
|5|6|
When formatted would appear as:
| column1 | column 2 |
| 5 | 6 |
I don't think the code would be hard to write and I may be able to get the algorithm from fitnesse, but I don't know how to write the plugin for eclipse.
Thanks

Related

Photoshop datasets and variables from csv limited to 99?

We're using Photoshops ability to import datasets from CSV to produce some ID cards for an event. We merge separate PNG's together and the output them using the "Export/Datasets as files" function
The CSV is set up as
|ID | Image1 |Image 2 |
| - | ------------- |---------------|
| 1 | path to X.png | path to Z.png |
| 2 | path to Y.png | path to W.png |
Repeated for about 200 rows with different images.
The issue we have is anything beyond the 99th row pulls the error
"Could not apply the dataset as the replacement file was not found" There are no issues with the file paths. If you substitute a post 100 row into a row pre 100 it works fine.
As if there is a hard limit of the number of rows we can have in a imported csv. I can't find any documentation from adobe as to any hard limit. And this "bug" is present in both a copy of cs6 and photoshop 2021. 1-99 work absolutely perfectly.
Does anyone have any workarounds. Or an alternative method of doing this?

Failed to convert Jbehave named parameters without delemeters

We are using Serenity with Jbehave for out automation stories, and we have recently upgraded our version to Serenity(2.2.1) and jbejave(1.46.0). Jbehave-core updated from 4.1.3 to 4.4. After the update i am facing an issue with examples table. it is forcing to use delimiter for the step table provided which is taken from story Examples.
This worked previously and got expected values into table
Scenario: Verify scenario
Meta:
Given modal should contains the next content:
{transformer=FROM_LANDSCAPE}
| modalTitle | expectedTitle1 |
| modalFooterTitle | expectedFooterTitle |
Examples:
{transformer=FROM_LANDSCAPE}
| expectedTitle1 | this is first expected title |
| expectedFooterTitle | This is expected footer text |
Now i have to use delimiter to get my expected content into table as below
Given product modal should contains the next content:
{transformer=FROM_LANDSCAPE}
| modalTitle | <expectedTitle1> |
| modalFooterTitle | <expectedFooterTitle> |
Examples:
{transformer=FROM_LANDSCAPE}
| expectedTitle1 | this is first expected title |
| expectedFooterTitle | This is expected footer text |
Also tried with configuration steps like ParameterControls().useDelimiterNamedParameters(false) but didn't worked. We have already implemented thousands of stories and it is hard to replace storied with delimiters. is there any work around to solve my problem?

Table headers with arbitrary locations in Github flavored markdown

In the gfm documentation, the examples for tables always have the table headers at the top.
| foo | hello |
| --- | ----- |
| bar | test |
Is there a way to place the headers in arbitrary locations, for example to have headers on the top and side? This can be done using HTML to make the table, however is there a solution to this without using HTML?
No, there is no way to do this without using HTML.

Selenium IDE: If variable contains some text

In the Selenium IDE Firefox add-on I'm trying to create an If statement that will execute a one way if my variable contains a certain text and will execute another way if it contains other text. The issue I'm having is I need it to check just one or two words in a long text so I can't use ==. What I've been trying to do is:
Command | Target | Value
Store Value | id = stuff | Test
If | ${Test}.contains('text') |
But this hasn't been working. Any help with this is greatly appreciated!
I use this contraction for such cases.
Command | Target | Value
Store Value | id = stuff | Test
execute script | var t = ${Test}; return t.contains('text'); | tmp
If | ${tmp}=='true' |

Formatting tables in Swift documentation comments

I have a section of code like this sitting above my computed property:
/**
Data Types Conversions:
-----------------------
+-----------------+-------------+
| kernel | Swift/Obj-c |
+=================+=============+
| sampler | CISampler |
| __table sampler | CISampler |
| __color | CIColor |
| float | NSNumber |
| vec2/3/4 | CIVector |
+-----------------+-------------+
*/
When it is rendered in the formatted comments pop-up I see garbled text.
Is there a way to represent this data in a table that actually renders when you option-click on the associated computed property?
I solved this problem with a code indent.
I don't know of any code markup for tabular formatting like that. I suggest you check Apple's site on their code documentation format:
https://developer.apple.com/library/content/documentation/Xcode/Reference/xcode_markup_formatting_ref/Throws.html#//apple_ref/doc/uid/TP40016497-CH26-SW1
You can also do this without indenting by using a "fenced" code block, surrounding your table (or code block) by triple backticks (```), the same way it works on stack overflow. But indenting may be cleaner and save vertical space.