| 1 |
/****************************************************************************** |
| 2 |
This source file is part of the Avogadro project. |
| 3 |
This source code is released under the 3-Clause BSD License, (see "LICENSE"). |
| 4 |
******************************************************************************/ |
| 5 |
|
| 6 |
#ifndef AVOGADRO_QTPLUGINS_TEMPLATETOOLKEYMAP_H |
| 7 |
#define AVOGADRO_QTPLUGINS_TEMPLATETOOLKEYMAP_H |
| 8 |
|
| 9 |
#include <QtCore/QString> |
| 10 |
|
| 11 |
#include <map> |
| 12 |
|
| 13 |
namespace Avogadro { |
| 14 |
namespace QtPlugins { |
| 15 |
|
| 16 |
// Lookup table mapping key buffer strings to fragment CJSON paths |
| 17 |
// for the ligands tab (currentTab == 1) |
| 18 |
inline const std::map<QString, QString>& ligandKeyMap() |
| 19 |
{ |
| 20 |
static const std::map<QString, QString> keyMap = { |
| 21 |
// Monodentate |
| 22 |
{ "a", "1-aqua" }, |
| 23 |
{ "co", "1-carbonyl" }, |
| 24 |
{ "cn", "1-cyano" }, |
| 25 |
{ "n", "1-ammine" }, |
| 26 |
{ "o", "1-aqua" }, |
| 27 |
{ "p", "1-phosphine" }, |
| 28 |
{ "pyr", "1-pyridyl" }, |
| 29 |
{ "s", "1-thiol" }, |
| 30 |
// Bidentate |
| 31 |
{ "acac", "2-acetylacetonate" }, |
| 32 |
{ "bpy", "2-bipyridine" }, |
| 33 |
{ "dmg", "dimethylglyoxime" }, |
| 34 |
{ "dmpe", "dmpe-1,2-bis(dimethylphosphino)ethane" }, |
| 35 |
{ "dppe", "dppe-1,2-bis(diphenylphosphino)ethane" }, |
| 36 |
{ "en", "2-ethylenediamine" }, |
| 37 |
{ "ox", "oxalate" }, |
| 38 |
{ "phen", "phenanthroline" }, |
| 39 |
// Tridentate |
| 40 |
{ "tpy", "3-terpyridine" }, |
| 41 |
// Tetradentate |
| 42 |
{ "pc", "4-phthalocyanine" }, |
| 43 |
{ "por", "4-porphin" }, |
| 44 |
{ "sal", "4-salen" }, |
| 45 |
// Hexadentate |
| 46 |
{ "edta", "6-edta" }, |
| 47 |
// Haptic |
| 48 |
{ "cp", "eta5-cyclopentyl" }, |
| 49 |
{ "e2", "eta2-ethylene" }, |
| 50 |
{ "e3", "eta3-alyl" }, |
| 51 |
{ "e4", "eta4-cyclo-octadiene" }, |
| 52 |
{ "e5", "eta5-cyclopentyl" }, |
| 53 |
{ "e6", "eta6-benzene" }, |
| 54 |
}; |
| 55 |
return keyMap; |
| 56 |
} |
| 57 |
|
| 58 |
// Lookup table mapping key buffer strings to fragment CJSON paths |
| 59 |
// for the functional groups tab (currentTab == 2) |
| 60 |
inline const std::map<QString, QString>& groupKeyMap() |
| 61 |
{ |
| 62 |
static const std::map<QString, QString> keyMap = { |
| 63 |
// Aromatic |
| 64 |
{ "a", "phenyl" }, |
| 65 |
// Alkyl chains (n-alkyl) |
| 66 |
{ "c1", "1-methyl" }, |
| 67 |
{ "c2", "ethyl" }, |
| 68 |
{ "c3", "propyl" }, |
| 69 |
{ "c4", "butyl" }, |
| 70 |
{ "c5", "pentyl" }, |
| 71 |
{ "c6", "hexyl" }, |
| 72 |
{ "c7", "heptyl" }, |
| 73 |
{ "c8", "octyl" }, |
| 74 |
{ "c9", "nonyl" }, |
| 75 |
{ "c0", "decyl" }, |
| 76 |
// Cycloalkyl |
| 77 |
{ "C3", "cyclopropane" }, |
| 78 |
{ "C4", "cyclobutane" }, |
| 79 |
{ "C5", "cyclopentane" }, |
| 80 |
{ "C6", "cyclohexane" }, |
| 81 |
{ "C7", "cycloheptane" }, |
| 82 |
{ "C8", "cyclooctane" }, |
| 83 |
{ "C9", "cyclononane" }, |
| 84 |
{ "C0", "cyclodecane" }, |
| 85 |
// Branched alkyl |
| 86 |
{ "I", "iso-propyl" }, |
| 87 |
{ "K", "t-butyl" }, |
| 88 |
// others |
| 89 |
{ "boc", "boc-tert-butyloxycarbonyl" }, |
| 90 |
{ "c", "1-methyl" }, |
| 91 |
{ "C", "carboxylate" }, |
| 92 |
{ "cbz", "cbz-benzyloxycarbonyl" }, |
| 93 |
{ "cm", "t-butyl" }, |
| 94 |
{ "cn", "nitrile" }, |
| 95 |
{ "co", "aldehyde" }, |
| 96 |
{ "co2", "carboxylate" }, |
| 97 |
{ "cs", "thial" }, |
| 98 |
{ "cso", "carbothioic_O-acid" }, |
| 99 |
{ "E", "ester" }, |
| 100 |
{ "ep", "epoxide" }, |
| 101 |
{ "F", "trifluoromethyl" }, |
| 102 |
{ "fmoc", "fmoc-fluorenylmethoxycarbonyl" }, |
| 103 |
{ "H", "cbz-benzyloxycarbonyl" }, |
| 104 |
{ "im", "imine" }, |
| 105 |
{ "L", "trichloromethyl" }, |
| 106 |
{ "mes", "mesityl" }, |
| 107 |
{ "ms", "mesyl" }, |
| 108 |
{ "N", "nitro" }, |
| 109 |
{ "nc", "isocyano" }, |
| 110 |
{ "ncs", "isothiocyanate" }, |
| 111 |
{ "nn", "azo" }, |
| 112 |
{ "no", "nitroso" }, |
| 113 |
{ "no2", "nitro" }, |
| 114 |
{ "n3", "azide" }, |
| 115 |
{ "O", "peroxide" }, |
| 116 |
{ "om", "methoxy" }, |
| 117 |
{ "ono", "nitrite" }, |
| 118 |
{ "oo", "peroxide" }, |
| 119 |
{ "otf", "triflate" }, |
| 120 |
{ "P", "phosphate" }, |
| 121 |
{ "po3", "phosphate" }, |
| 122 |
{ "Q", "fmoc-fluorenylmethoxycarbonyl" }, |
| 123 |
{ "R", "tribromomethyl" }, |
| 124 |
{ "S", "sulfonate" }, |
| 125 |
{ "scn", "thiocyanate" }, |
| 126 |
{ "so3", "sulfonate" }, |
| 127 |
{ "ss", "disulfide" }, |
| 128 |
{ "T", "troc-2,2,2-trichloroethoxycarbonyl" }, |
| 129 |
{ "tf", "triflyl" }, |
| 130 |
{ "tos", "tosyl" }, |
| 131 |
{ "tr", "trityl" }, |
| 132 |
{ "ts", "tosyl" }, |
| 133 |
{ "troc", "troc-2,2,2-trichloroethoxycarbonyl" }, |
| 134 |
{ "V", "ethylene" }, |
| 135 |
{ "W", "ethyne" }, |
| 136 |
{ "Y", "boc-tert-butyloxycarbonyl" }, |
| 137 |
}; |
| 138 |
return keyMap; |
| 139 |
} |
| 140 |
|
| 141 |
} // namespace QtPlugins |
| 142 |
} // namespace Avogadro |
| 143 |
|
| 144 |
#endif // AVOGADRO_QTPLUGINS_TEMPLATETOOLKEYMAP_H |