merge qml tags file, with lex file for presentation? - tags

I have no knowledge to qml, qt, or c++ for that part.
but my problem is that I have this .lex file, which is really only xml, and some files that end With .qml, like this one frontpagetemplate.qml.
The format in here is unknown too me.
<qt title="{book_name}">
<h1>{book_name}</h1>
<br/>
<!-- BEGIN paragraph_tpl -->
<!-- BEGIN paragraph_html_tpl -->
{html}
<!-- END paragraph_html_tpl -->
<!-- BEGIN paragraph_header_tpl -->
<h2>{header}</h2>
<!-- END paragraph_header_tpl -->
<!-- BEGIN paragraph_text_tpl -->
<p>{text}</p>
<!-- END paragraph_text_tpl -->
<!-- BEGIN paragraph_link_tpl -->
<p>{link_name}</p>
<!-- END paragraph_link_tpl -->
<!-- BEGIN paragraph_olist_tpl -->
<ol type="{list_type}">
<!-- BEGIN olist_item_tpl -->
<li>{text}</li>
<!-- END olist_item_tpl -->
</ol>
<!-- END paragraph_olist_tpl -->
<!-- BEGIN paragraph_ulist_tpl -->
<ul type="{list_type}">
<!-- BEGIN ulist_item_tpl -->
<li>{text}</li>
<!-- END ulist_item_tpl -->
</ul>
<!-- END paragraph_ulist_tpl -->
<!-- BEGIN paragraph_table_tpl -->
<table {bgcolor} {width} border="{border}" cellspacing="{cellspacing}" cellpadding="{cellpadding}">
<!-- BEGIN table_tr_tpl -->
<tr {bgcolor}>
<!-- BEGIN tr_th_tpl -->
<th {bgcolor} {width} colspan="{colspan}" rowspan="{rowspan}" align="{align}">{text}</th>
<!-- END tr_th_tpl -->
<!-- BEGIN tr_td_tpl -->
<td {bgcolor} {width} colspan="{colspan}" rowspan="{rowspan}" align="{align}">{text}</td>
<!-- END tr_td_tpl -->
</tr>
<!-- END table_tr_tpl -->
</table>
<!-- END paragraph_table_tpl -->
<!-- BEGIN paragraph_image_tpl -->
<p><img src="{img_src}" /></p>
<!-- END paragraph_image_tpl -->
<!-- END paragraph_tpl -->
<table border>
<tr>
<th align="left">ID</th>
<td>{book_id}</td>
</tr>
<tr>
<th align="left">Created</th>
<td>{created}</td>
</tr>
<tr>
<th align="left">Last modified</th>
<td>{modified}</td>
</tr>
<tr>
<th align="left">Publisher ID</th>
<td>{publisher_id}</td>
</tr>
<tr>
<th align="left">Publisher</th>
<td>{publisher_name}</td>
</tr>
</table><br/>
</qt>
What is this syntax, is there any editor out there?
Can I convert it to html?
I really have problems finding any info on this. all I find about qml, is something that looks like JavaScript variant.
My goal is to merge these files and make a html presentation of the tags and the data in the .lex file, rather than the ugly-looking lexion it is in today.

The file you posted is definitely a variant on html. Hopefully someone else will recognize it right off as whatever kit it is part of. Perhaps it is rich text, perhaps some other format--but replace qt with html and you'll see it marked up in a web browser.
QML is a language that uses JavaScript style syntax for building applications. In my opinion it is a lot of fun to work with. You can download an IDE at:
http://qt-project.org/
My guess is you have a Qt Quick application that you're looking at, I'd venture a guess at Qt4 but I'm new to the toolkit so my knowledge is rather contemporary.

Related

multi-column template for Cleverreach

I'm trying to write a multi-column template for Cleverreach. We need a one-column for the main-content and below this a two- or three-column area for products (dynamic content from MyContent-API).
All my tries dosn't work, it's seems only possible to define one-column areas (loop-areas) for placing content-elements in Cleverreachs WYSIWYG-editor.
If I define more than one loop-areas, only the last area is displayed in WYSIWYG-editor, alls others are gone.
Has someone resolved such a problem? Somthing like:
<table><tr><td><!-- #loop# --> <!-- #/loop# --></td>
<td><!-- #loop# --> <!-- #/loop# --></td></tr></table>
(this example will result in, that only the second column is displayed in WYSIWYG-editor.
Kind regard
Johannes
It#s important, that each loop has a unique numerous ID
<table>
<tr>
<td>
<!-- #loop# --> <!-- loop1 -->
some code
<!--#/loop# -->
</td>
<td>
<!-- #loop# --> <!-- loop2 -->
some other code
<!-- #/loop# -->
</td>
</tr>
</table>

MailChimp custom template problems with drag and drop blocks

I am creating a custom MailChimp template but having issues when using the mc:repeatable element. I have it on a wrapped around a block of code and in the editor when creating a campaign, it works fine, I can spawn a new version of the parent block and move it around in the template, but when I preview, or send the email, the child block that was spawned from the parent sits below it's parent and not where I have placed it following spawning it from the parent block... Something seems to be wrong? (Heavily simplified) Code example below... Anyone any ideas on the fix???
<!-- BLOCK A -->
<div style="width:100%" mc:repeatable="CONTENTBLOCK_A">
<p>This is block A</p>
</div>
<!-- end of BLOCK A -->
<!-- BLOCK B -->
<div style="width:100%" mc:repeatable="CONTENTBLOCK_B">
<p>This is block B</p>
</div>
<!-- end of BLOCK B -->
So, when creating a new campaign, if I duplicate BLOCK A and position the duplicated BLOCK A below BLOCK B - in the preview within the campaign editor it looks fine, but when I click to view it into PREVIEW MODE, or send a PREVIEW EMAIL - the duplicated BLOCK A sits above BLOCK B and below its original spawned parent BLOCK A element...
Any ideas? Are the HTML COMMENTS (e.g. < !-- --> ) The issue perhaps?
Very late, but I was able to find success using this:
<table mc:repeatable="content" mc:variant="variant_1">
<tr>
<td mc:edit="section_1">
Variant 1 Content
</td>
</tr>
</table>
<table mc:repeatable="content" mc:variant="variant_2">
<tr>
<td mc:edit="section_2">
Variant 2 Content
</td>
</tr>
</table>
<table mc:repeatable="content" mc:variant="variant_3">
<tr>
<td mc:edit="section_3">
Variant 3 Content
</td>
</tr>
</table>
More in depth explanation can be found here: Create Editable Content Areas with MailChimp’s Template Language

Invoking Linker Cross-Site-Iframe Ignoring the following script tags in the gwt.xml file

//Smart_gwt_exmp.gwt.xml
<?xml version="1.0" encoding="UTF-8"?>
<module rename-to='smart_gwt_exmp'>
<inherits name='com.google.gwt.user.User'/>
<inherits name="com.smartgwt.SmartGwt"/>
<inherits name='com.google.gwt.user.theme.standard.Standard'/>
<entry-point class='package2.client.Smart_gwt_exmp'/>
<source path='client'/>
<source path='shared'/>
<add-linker name="xsiframe"/>
<set-configuration-property name='xsiframe.failIfScriptTag' value='FALSE'/>
</module>
//Smart_gwt_exmp.html
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<link type="text/css" rel="stylesheet" href="Smart_gwt_exmp.css">
<title>Web Application Starter Project</title>
<script src="smart_gwt_exmp/sc/modules/ISC_Calendar.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_Containers.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_Core.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_DataBinding.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_Drawing.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_Foundation.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_Grids.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_History.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_PluginBridges.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_RichTextEditor.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_Scheduler.js"></script>
<script src="smart_gwt_exmp/sc/modules/ISC_Workflow.js"></script>
<script type="text/javascript" language="javascript"
src="smart_gwt_exmp/smart_gwt_exmp.nocache.js"></script>
</head>
<body>
<!-- OPTIONAL: include this if you want history support -->
<iframe src="javascript:''" id="__gwt_historyFrame" tabIndex='-1'
style="position:absolute;width:0;height:0;border:0"></iframe>
<!-- RECOMMENDED if your web app will not function without JavaScript enabled -->
<noscript>
Your web browser must have JavaScript enabled
in order for this application to display correctly.
</div>
</noscript>
<h1>Web Application Starter Project</h1>
<table align="center">
<tr>
<td colspan="2" style="font-weight:bold;">Please enter your name:</td>
</tr>
<tr>
<td id="nameFieldContainer"></td>
<td id="sendButtonContainer"></td>
</tr>
<tr>
<td colspan="2" style="color:red;" id="errorLabelContainer"></td>
</tr>
</table>
</body>
</html>
//Smart_gwt_exmp.java
package package2.client;
import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.user.client.ui.RootPanel;
import com.smartgwt.client.util.SC;
import com.smartgwt.client.widgets.IButton;
import com.smartgwt.client.widgets.form.DynamicForm;
import com.smartgwt.client.widgets.form.fields.TextItem;
/**
* Entry point classes define <code>onModuleLoad()</code>.
*/
public class Smart_gwt_exmp implements EntryPoint {
public void onModuleLoad() {
DynamicForm form=new DynamicForm();
}
}
//Error during compilation
//Compiling 5 permutations
// Compiling permutation 0...
// Compiling permutation 1...
// Compiling permutation 2...
// Compiling permutation 3...
// Compiling permutation 4...
// Compile of permutations succeeded
// Linking into C:\Users\rsoni\workspace\smart_gwt_exmp\war\smart_gwt_exmp
// Invoking Linker Cross-Site-Iframe
// Ignoring the following script tags in the gwt.xml file
// sc/modules/ISC_Core.js
// sc/modules/ISC_Foundation.js
// sc/modules/ISC_Containers.js
// sc/modules/ISC_Grids.js
// sc/modules/ISC_Forms.js
// sc/modules/ISC_RichTextEditor.js
// sc/modules/ISC_Calendar.js
// sc/modules/ISC_DataBinding.js
// sc/skins/Enterprise/load_skin.js
//Link succeeded
//Compilation succeeded -- 92.377s
//Note : when i try to compile the above code the compiler gives me the error .The //error i have pasted in the above code along with the output.
The std linker uses document.write() to load the script files and make sure they're loaded before the onModuleLoad is called.
The xsiframe is a much better web citizen and loads everything asynchronously, without document.write(). That means it cannot provide those ordering guarantees, so to make the implementaition simpler and, most importantly, reliable, it doesn't support <script>s in the gwt.xml files.
By default, it fails the build if you have a <script>. You can turn the error into a warning using the xsiframe.failIfScriptTag configuration property, but then it ignores the <script>s, so you still have to load them by yourself, either right from your HTML host page (like you did BTW, so assuming you listed all needed files, it should work), or using the ScriptInjector.

Plugin for sublime text 2? Exists?

Looking plugin ST2 in which this can:
Do U know a Emment (previously version has named ZenCoding).
When u try this example =>
div#wrapper>div.someclass>p.class2{text}|c + tab
===>
<div id="wrapper">
<div class="someclass">
<p class="class2">text</p>
<!-- /.class2 -->
</div>
<!-- /.someclass -->
</div>
The difference is that this I use the finished text (Emmet it knows when it write from scratch)

Two forms where the second reads the first form

I have two nearly identical forms on a page with two buttons, one for each form.
Now I want the second button to also read data from the fields of the first form and hide the fields of the second form or not have them. How can I do that?
the first form
<form:form id="excelform" commandName="tg35FormBackingModel" action="${createExcel}" method="post">
<div>
<table>
<tr>
<td class="tg35-left"><spring:message code="tg35.fromDate" />
<em title="<spring:message code='tooltip.mandatory' />"
class="mandatory float-right">*</em>
</td>
<td><form:input path="fromDate" cssClass="dateInput" /> <form:errors
cssClass="ui-state-error ui-corner-all" path="fromDate" />
</td>
</tr>
...