In my xml :
sachin
nitin
ravi
deepak
i have created "tag1" object style in indesign template. because i want to apply background style for "tag1", but this should not manually, because there is multiple occurrence. please suggest how to map object style to "tag1" automatically.
You can do two things:
In your template open Structure panel, select from the top menu and "Map tags to styles". Here you can assign multiple tags to the same style and save it.
The other option is to add style link as an attribute to your xml. I know it works with paragraph style, not sure about the object styles: E.g.
<sachin aid:pstyle="tag1">
You will need to add an adobe namespace to your xml.
Related
There is this Look and Feel option in every portlet settings:
I want to create hook for this tab. Which JSP file do I have to override?
How can I add my custom field in this tab (like Use Custom Title)?
How to find such files:
Look into src/content/Language.properties for a term from your screen with high significance, e.g. Use Custom Title:
...
use-custom-title=Use Custom Title
...
Now search for a file that contains the key, in our case use-custom-title:
portal-web/docroot/html/portlet/portlet_css/view.jsp
That is indeed the file you are looking for.
I have just started messing with Telerik Reporting in an MVC C# application.
Since I need to create a dozen of reports, I was asked to create an external style to be aplied to all of them.
I cannot understand how it works, how to set the rules...
Eg I can create a style to affect all HtmlTextBoxes BUT I am trying to create a rule to have all the HtmlTextBoxes contained in the Group Header having (lets say) blue Background, Bold Segoi Font and I cannot.
Any help appreciated
Styles created in a Telerik Report can be exported and then used in other reports.
You can store one or more Styles in an exported file.
The exported information is stored in an XML file.
So you can create your style rules using the Style context menu Right-clicking on the report object.
Style exporting and reusing style sheets
Use various Style Selectors to define how a style will be applied globally to items in a report. Each Style Rule that you create (either in code or using the StyleRule Collection Editor) must be created as one of the basic four selector.
Learn more about style selector.. For me the best one is the "StyleSelector" that behave like a Css Class.
Nb:
You can manage and bind your extenal StyleSheet in code behind.
Or in your calling application.
this.StyleSheet.Clear();
this.ExternalStyleSheets.Add(
new Telerik.Reporting.Drawing.ExternalStyleSheet("baseThemeRpt.xml"));
It can be done using the Descendant Type
Is there a way to add a tag to the format dropdown that would wrap the text in <small></small> tags?
Editing config.js as follows causes a runtime error:
config.format_tags = 'small;p;h1;h2;h3;pre';
probably because <small> is not block level?
The reason of the runtime error is, that js can not find CKEDITOR.config.format_small.
You have to do two things:
Search for CKEDITOR.config.format_h6 in ckeditor.js and add CKEDITOR.config.format_small={element:"small"};. Then the error is gone, but you can not see the entry yet.
open the languagefile you want (e.g. en.js) and add "tag_small":"small text".
now CKEditor supports the small tag.
This works for me, I hope it works for you too.
If I want to add a custom section tag to format tags, this work for me:
1. Go to config.js, add
config.format_tags = 'h1;h2;h3;h4;h5;h6;section';
config.format_section = { element : 'section' };
2. Then open the languagefile you want (e.g. en.js) -> lang/en.js
search for "tag_pre":"Formatted", and add "tag_section":"Section".
If you're looking to wrap text in a certain tag, you can also achieve this with the Style dropdown as well.
First, configure your editor to allow styles at /admin/config/content/formats/manage/full_html. Replace full_html with whatever editor version you want to modify
Drag the Styles button to the active toolbar if it isn't already there
Add items to "Styles Dropdown" tab under CKEditor plugin settings
Each option takes the form css_selector | Human Visible Name so in your case, you'd add small.my_element_class | Super Special Small or something similar.
Instructions abbreviated from this post: https://www.axelerant.com/resources/team-blog/drupal-8-custom-styles-in-ckeditor
I am Using CKEditor in my application where the users can write blogs, create pages etc..,
Source mode is disabled for the editor. Writing xml in the editor's text area is not retained after saving the content. I clearly see that the content got HTML Encoded and the same is supplied as input to the CKEditor's textarea.
Works as designed. Whatever you enter into the WYSIWYG area, will get HTML encoded. How would you want to behave it differently?
If you want a text editor for writing XML, maybe the answers to this question are useful: Textarea that can do syntax highlighting on the fly?
I too want CKEditor to support XML tags, but I understand that you can't just type them into the main window - anything typed here is assumed to be actual content, not tagging, and therefore gets encoded.
What I'd like to do is define a list of styles that cause a tag of my choosing to be used, e.g. if the user chooses the 'example' style, CKEDitor does <x>content</x>. Unfortunately I haven't had much success with this, despite hacking the dtd.js file.
My current solution is to define a list of styles but map them to a standard HTML tag, then put my desired XML tag name in as an attribute. I'll then need to write some XSLT that transforms the data later.
CKEDITOR.stylesSet.add('myStyles',
[{
name: 'Example sentence',
element: 'span',
attributes: {'class': 'example', 'data-xmlTag': 'x'}
}];
config.stylesSet = 'myStyles';
element specifies a standard HTML tag – I use <span> if I want the XML to be inline and <div> if I want it to be block level. The data-xmlTag attribute says what XML tag I actually wanted to use (x in this case). The class allows me to define some styles in CSS and means I can group several XML tags under one class name. To define some CSS:
config.contentsCss = CKEDITOR.basePath+'tagStyles.css';
How can I set text direction [rtl] on load editor?
According to the docs, this should do it:
CKEDITOR.config.contentsLangDirection in the CKSource manual
Example taken from there:
config.contentsLangDirection = 'rtl';
Another way to do it is directly from your view file, the benefit of using replace() method is that you can use different direction and style for each of your view.
CKEDITOR.replace( 'article_area', {
contentsLangDirection: 'rtl'
} );
By using replace() you can also do other filtering stuff like allowing/disallowing tags and removing buttons from the editor. for a detailed description visit:
http://ckeditor.com/ckeditor_4.1rc/samples/datafiltering.html
If you use CKEditor version 5, the config block is like:
language: {
ui: 'en',
content: 'ar'
}
Where in this example, the editor itself will remain in english (both headings and orientation) and the content will be edited in arabic (therefore right to left).
I chose this example to illustrate that it's possible to use different languages for these two purposes (say if you build a CMS with the text editor and admins want to add arabic or hebrew translations for different site content but interact with the editor itself in english). But you could also set ui: 'ar' in order to mirror the editor itself as well (note that to do this I think you have to bundle in the languages in one of several ways, see the links below for reference).
The support for bidirectional text seems to be good (aka type something in Arabic and then type in english and it automatically switches to left-to-right only while you type in english).
References:
https://ckeditor.com/blog/CKEditor-5-v12.4.0-with-image-resizing-to-do-lists-RTL-language-support-and-more/
and the linked
https://ckeditor.com/docs/ckeditor5/latest/features/ui-language.html#righttoleft-rtl-languages-support
CKEDITOR.replace('editor1', {
language: 'es',
removeButtons: 'PasteFromWord'
});
just change the ContentsLangDirection="Rtl" inside the CkEditor like below
<CKEditor:CKEditorControl ID="CKEdMainPageDescriptionWebsiteMobileappAr" BasePath="ckeditor/" runat="server" Width="100%" Toolbar="Basic" ContentsLangDirection="Rtl"
ToolbarBasic="|Bold|Italic|Underline|Strike|-|NumberedList|BulletedList|Outdent|Indent|-|JustifyLeft|JustifyCenter|JustifyRight|JustifyBlock|
|Styles|-|Format|-|Font|-|FontSize|
/
|Link|Unlink|-|TextColor|-|Undo|Redo|Cut|Copy|Paste|PasteText|PasteFromWord|"> </CKEditor:CKEditorControl>
As of version 5, the direction can be set by changing language settings. You can see more details here.