Minggu, 29 April 2018

Sponsored Links

Carbon tetrachloride - Wikipedia
src: upload.wikimedia.org


Video Template talk:Chembox SMILES



Please remove display:none; it makes the formula invisible.

{{editprotected}} Please get rid of "display: none" in the list_style; this is the wrong way to get an initially collapsed list. See the information at Template talk:Collapsible list for background. It is not necessary, because lists are collapsed by default now in any case.

This technique has the problem that it produces a blank infobox entry for anyone with javascript disabled. (Template:Chembox InChI has the same problem.)

The rendered HTML is:

  | [[Simplified molecular input line entry specification|SMILES]]  | <small><tt><div class="NavFrame collapsed" style="border:none; padding:0;">      <div class="NavHead" style="width:100%; background:transparent;" align="left"> </div>      <div class="NavContent" style="text-align:left;display:none;">{{{value}}}</div>  </div></tt></small>  |-  

In the longer term, SMILES is very concise; many compounds have SMILES formulae which would not clutter up an infobox. (e.g. Alanine, Cytosine, Leucine) There should be a way to indicate that the formula is short and doesn't need hiding. The blank title ends up looking funny when the formula is expanded if it's very small. (If only we had mw:Extension:StringFunctions enabled, it could be done automatically using {{#len:}}, hint, hint.) 71.41.210.146 (talk) 13:30, 18 September 2009 (UTC)

I'd do it myself, but there seems to be a binge of template-protection lately.

Done. I'm looking around for other chembox templates do this now. -- RockMFR 23:06, 18 September 2009 (UTC)

Maps Template talk:Chembox SMILES



Drop support for value2 and value3

{{editprotected}} The value2 and value3 parameters, which correspond to the obsolete FullSMILES and DispSMILES parameters, are not used anywhere on Wikipedia, as shown by the emptiness of Category:Chembox SMILES maintenance. Thus, all mention of them can be deleted from the template. I.e. it can be simplified to

  | [[Simplified molecular input line entry specification|SMILES]]  | <small><tt>{{Collapsible list|title = &nbsp; |1={{{value|}}} }}</tt></small>  |-  

The call site in Template:Chembox Identifiers can also be simplified, from

  {{Chembox entry|par_name={{#if:{{{SMILES|}}}{{{FullSMILES|}}}{{{DispSMILES|}}}|SMILES }}                 |par_value={{#if:{{{SMILES|}}}|{{{SMILES}}} }} |par_value2={{#if:{{{FullSMILES|}}}|{{{FullSMILES}}} }}|par_value3={{#if:{{{DispSMILES|}}}|{{{DispSMILES}}} }} }}  

to

  {{Chembox entry|par_name={{#if:{{{SMILES|}}}|SMILES}} |par_value={{{SMILES}}} }}  

(There's no need to conditionalize the par_value, because Template:Chembox entry already checks for a null par_name.) 71.41.210.146 (talk) 05:01, 22 September 2009 (UTC)

 Done, please don't forget to update the template documentation. --TheDJ (talk o contribs) 10:40, 22 September 2009 (UTC)

Calcium chloride - Wikipedia
src: upload.wikimedia.org


Proposed change: Improve display

{{editprotected}} Not Yet Done -- currently under discussion.

I was thinking that the blank line at the beginning of the expanded infobox looks ugly. And the long text (even when <small>) messes up the table formatting. One possibility is to make the entire thing 2 columns wide. A couple of examples are in the infobox to the right. (Notice the two SMILES boxes, so you can compare the two.) The PCAA example shows how the extra width lets long formulae fit on one line. The one trick is the rather odd title_style syntax required by Template:Collapsible list to ensure the title is not bold.

Please try with Javascript on and off to see which you think looks better. In template form, the code would look like

  colspan=2| <small>{{Collapsible list |title_style=width:100%; background:transparent; font-weight:normal;" align="left |title=[[Simplified molecular input line entry specification|SMILES]] |list_style=text-align:right |1=<small><tt>{{#if:{{{value3|}}}|{{{value3}}}|{{{value|}}}}}</tt></small> }}{{#if:{{{value2|}}}{{{value3|}}}|[[Category:Chembox SMILES maintenance]]  

I'm preserving the existing use of value3, even though I don't understand it. Given that nothing uses it (Category:Chembox SMILES maintenance is empty), perhaps it should be deleted.

(Oh, and if this is accepted, a similar edit should be performed to Template:Chembox InChI.)

I removed the editprotected, I think this should first be discussed. This seems to work fine and nice, and is certainly a solution that could be implemented for all the collapsed boxes. What do others think? --Dirk Beetstra T C 14:00, 20 September 2009 (UTC)

Template available for test

The modified version is available as {{Chembox SMILES/sandbox}} for experimentation, which is unprotected (editable). To see it in action, replace {{Chembox Identifiers}} with {{Chembox Identifiers/sSandbox}} and hit "preview". Both versions of the SMILES template will appear.

One solution to the problem of SMILES formulae being too long may be to insert soft-hyphen characters (­) in the formula. A hyphen is a legal (although usually omitted) SMILES character to indicate a single bond. 71.41.210.146 (talk) 12:47, 25 September 2009 (UTC)

Um, okay, that doesn't work. But Unicode Zero Width Space, &#8203;, does work. See the Ovalene example (which is several copies of the true SMILES pasted together), 71.41.210.146 (talk) 12:59, 25 September 2009 (UTC)

The idea of using 'broken' SMILES is something that we did not want (and that is why at first we had the other parameters in the box), It does display 'properly' at this end, but then it is a) not machine readable anymore (as it is 'not correct', or has to be corrected), b) if you look for the broken SMILES (e.g. using google) you might not find it, as, depending on the search engine, sites presenting unbroken SMILES may end up higher, or the search engine might not be able to find it anyway, and c) the other way around, if we would encapsulate our 'broken' SMILES into an external link into a search engine or a external chemical database, then the result may not be the correct one. It is a big dilemma on all sides, but if 'breaking' the SMILES would be a solution, then we would not even need to hide it. --Dirk Beetstra T C 14:26, 25 September 2009 (UTC)

By the way, I think that Opera does not understand the Zero Width Space, my SMILES looks strange, I don't even see carbon atoms anymre. --Dirk Beetstra T C 14:27, 25 September 2009 (UTC)


Platinum(II) chloride - Wikipedia
src: upload.wikimedia.org


Edit request on 15 February 2012

Ah, the law of intended consequences...

Please change "Simplified molecular input line entry specification|SMILES" to "Simplified molecular input line entry system|SMILES".

because the name of the SMILES article has changed.

Glrx (talk) 18:45, 15 February 2012 (UTC)

  •  Done --CapitalR (talk) 05:18, 16 February 2012 (UTC)

Potassium dichromate - Wikipedia
src: upload.wikimedia.org


Edit request on 3 May 2012


The SMILES hyperlink, Simplified molecular input line entry system, redirects to Simplified molecular-input line-entry system. Perhaps we should correct the hyphenation in the link to bypass the redirect. Ringbang (talk) 21:17, 3 May 2012 (UTC)


Potassium dichromate - Wikipedia
src: upload.wikimedia.org


Fix needed

Hi there, please see this message from a Parsoid developer who got a chance to review a few templates and suggests some fixes. Thanks a lot, --Elitre (WMF) (talk) 16:02, 25 October 2013 (UTC)

Source of the article : Wikipedia

Comments
0 Comments