Base toolkit upon which the software is built. More...
Detailed Description
Base toolkit upon which the software is built.
TODO. list in src/plugins/score-plugin-avnd/Crousti/Concepts.hpp#L139.
This namespace contains only non-domain specific classes and utilities : serialization, model-view, documents, etc.
It is split in two folders :
coreis the internal mechanic to set-up the software : the actual widget classes, the plug-in loading code, etc.scoreis the "public" part of the score API : this code can be used by plug-ins.
This file contains facilities to serialize an object into a QJsonObject.
This file contains base types for the events and transitions of the state machines in score.
See the documentation for explanation of the general pattern
Namespaces | |
| namespace | gfx |
| Graphics rendering pipeline for ossia score. | |
Typedefs | |
| using | JsonWriter = ossia::json_writer |
| using | GlobalSettingsPresenter = SettingsDelegatePresenter< SettingsDelegateModel > |
| using | ActionGroupKey = StringKey< ActionGroup > |
| using | ActionKey = StringKey< Action > |
| using | ActionConditionKey = StringKey< score::ActionCondition > |
| template<typename T1 , typename T2 > | |
| using | enable_if_base_of = std::enable_if< std::is_base_of< T1, T2 >::value, void * > |
| using | FindCommandKey = std::pair< CommandGroupKey, CommandKey > |
| using | MaybeDocument = const score::DocumentContext * |
| template<typename Component > | |
| using | ComponentHierarchy = ComponentHierarchyManager< Component, typename Component::model_t, typename Component::component_t > |
| template<typename Component , bool HasOwnership = true> | |
| using | PolymorphicComponentHierarchy = PolymorphicComponentHierarchyManager< Component, typename Component::model_t, typename Component::component_t, typename Component::component_factory_list_t, HasOwnership > |
| template<typename Model > | |
| using | HierarchicalComponents = HierarchicalMember< Model, score::Components, &Model::components > |
| using | InterfaceKey = UuidKey< InterfaceBase > |
| using | ProjectSettingsPresenter = SettingsDelegatePresenter< ProjectSettingsModel > |
| using | ProjectSettingsView = SettingsDelegateView< ProjectSettingsModel > |
| using | PluginKey = UuidKey< Plugin > |
| using | SettingsDelegateFactoryList = InterfaceList< score::SettingsDelegateFactory > |
| template<typename T > | |
| using | sp = SettingsParameterMetadata< T > |
| using | GlobalSettingsView = SettingsDelegateView< SettingsDelegateModel > |
| using | uuid_t = uuids::uuid |
| using | any_map = ossia::any_map |
| using | any_serializer_map = score::hash_map< std::string, std::unique_ptr< any_serializer > > |
| using | Press_Event = NumberedEvent< 1 > |
| using | Move_Event = NumberedEvent< 2 > |
| using | Release_Event = NumberedEvent< 3 > |
| using | Cancel_Event = NumberedEvent< 4 > |
| using | Shift_Event = NumberedEvent< 5 > |
| using | Press_Transition = MatchedTransition< Press_Event > |
| using | Move_Transition = MatchedTransition< Move_Event > |
| using | Release_Transition = MatchedTransition< Release_Event > |
| using | Cancel_Transition = MatchedTransition< Cancel_Event > |
| using | ShiftTransition = MatchedTransition< Shift_Event > |
| using | comparable_function = std::shared_ptr< std::function< void()> > |
| using | id_generator = score::linear_id_generator |
| template<class Key , class T > | |
| using | hash_map = ossia::hash_map< Key, T > |
Enumerations | |
| enum | Modifier_tagme { Click = 100 , Move = 200 , Release = 300 } |
| enum | TimeMode { Bars , Seconds , Flicks } |
Functions | |
| const ApplicationContext & | AppContext () |
| const GUIApplicationContext & | GUIAppContext () |
| const ApplicationComponents & | AppComponents () |
| void | setQApplicationMetadata () |
| template<typename RedoFun > | |
| void | loadCommandStack (const score::ApplicationComponents &components, DataStreamWriter &writer, score::CommandStack &stack, RedoFun redo_fun) |
| QString | newProcessedFilePath (const QString &sourceFile, const QDir &destination) |
| Obtains a new file name in the project folder to save a processed file. | |
| Id< score::DocumentModel > | getStrongId (const std::vector< score::Document * > &v) |
| ApplicationServices & | AppServices () noexcept |
| QString | toNumber (double v) noexcept |
| QString | toNumber (int v) noexcept |
| template<typename T > | |
| double | operator* (double lhs, const ValueAssigner< T > &rhs) noexcept |
| template<typename T > | |
| T & | component (const score::Components &c) |
| component Fetch a Component from Components by type | |
| template<typename T > | |
| T * | findComponent (const score::Components &c) noexcept |
| findComponent Tryies to fetch a Component from Components by type. | |
| template<typename T > | |
| auto | id (const Path< T > &path) |
| SCORE_LIB_BASE_EXPORT QString | addonArchitecture () |
| addonArchitecture | |
| template<typename DocPlugin > | |
| auto & | addDocumentPlugin (score::Document &doc) |
| void | debug_types (const InterfaceBase *orig, const InterfaceBase *repl) noexcept |
| std::vector< Plugin_QtInterface * > & | staticPlugins () |
| template<typename T , typename Model > | |
| void | setupDefaultSettings (QSettings &set, const T &tuple, Model &model) |
| score::hash_map< std::string, std::unique_ptr< any_serializer > > & | anySerializers () |
| The serializers for types that go in ossia::any should fit in here. | |
| template<typename Object > | |
| auto | unmarshall (const JSONReader &obj) |
| const StringConstants & | StringConstant () |
| template<typename T > | |
| void | serialize_dyn_impl (DataStream::Serializer &v, const T &t) |
| template<typename T > | |
| void | serialize_dyn_impl (JSONObject::Serializer &v, const T &t) |
| template<typename TheClass > | |
| void | serialize_dyn (const VisitorVariant &vis, const TheClass &s) |
| template<typename TheClass > | |
| TheClass & | deserialize_dyn (const VisitorVariant &vis, TheClass &s) |
| template<typename TheClass > | |
| TheClass | deserialize_dyn (const VisitorVariant &vis) |
| template<typename Functor > | |
| auto | deserialize_dyn (const VisitorVariant &vis, Functor &&fun) |
| template<typename Type , typename Object > | |
| auto | marshall (const Object &obj) |
| marshall Serializes a single object | |
| template<typename Object > | |
| auto | unmarshall (const rapidjson::Value &obj) |
| template<typename Object > | |
| auto | unmarshall (const QByteArray &arr) |
| template<typename Transition , typename SourceState , typename TargetState , typename... Args> | |
| Transition * | make_transition (SourceState source, TargetState dest, Args &&... args) |
| void | setCursorPos (QPointF pos) noexcept |
| void | moveCursorPos (QPointF pos) noexcept |
| QPoint | globalPos (QMouseEvent *event) |
| QPointF | globalPos (QWidget *viewport, QGraphicsSceneMouseEvent *event) |
| void | hideCursor (bool hasCursor) |
| void | showCursor () |
| template<typename T > | |
| void | clearAndDeleteLater (T &container, delete_later< T > &storage) noexcept |
| template<typename T > | |
| auto | clearAndDeleteLater (T &container) noexcept |
| QString | addUniqueSuffix (const QString &fileName) |
| QString | locateFilePath (const QString &filename, const score::DocumentContext &ctx) noexcept |
| QString | relativizeFilePath (const QString &filename, const score::DocumentContext &ctx) noexcept |
| QByteArray | mapAsByteArray (QFile &f) noexcept |
| std::string_view | mapAsStringView (QFile &f) noexcept |
| std::string | readFileAsString (QFile &f) noexcept |
| QString | readFileAsQString (QFile &f) noexcept |
| QStringList | list_ipv4_for_connecting () noexcept |
| QStringList | list_ipv4_for_listening () noexcept |
| void | for_all_files (std::string_view root, std::function< void(std::string_view)> f) |
| template<typename Map > | |
| void | optimize_hash_map (Map &map) |
| template<typename T > | |
| indirect_iterator< T > | make_indirect_iterator (const T &it) noexcept |
| template<typename T > | |
| indirect_ptr_iterator< T > | make_indirect_ptr_iterator (const T &it) |
| template<typename T > | |
| indirect_map_iterator< T > | make_indirect_map_iterator (const T &it) |
| template<typename CastTo , typename T > | |
| indirect_cast_map_iterator< T, CastTo > | make_indirect_cast_map_iterator (const T &it) |
| template<typename T > | |
| auto | wrap_indirect (T &container) |
| void | setCursor (Qt::CursorShape c) |
| setCursor sets the cursor safely. | |
| SCORE_LIB_BASE_EXPORT const QPalette & | transparentPalette () |
| void | setHelp (QWidget *widg, const QString &shorttxt, const QString &txt) |
| void | setHelp (QAction *widg, const QString &shorttxt, const QString &txt) |
| void | setHelp (QWidget *widg, const QString &txt) |
| void | setHelp (QAction *widg, const QString &txt) |
| int | question (QWidget *parent, const QString &title, const QString &text) |
| int | information (QWidget *parent, const QString &title, const QString &text) |
| int | warning (QWidget *parent, const QString &title, const QString &text) |
| QImage | get_image (QString str) |
| QPixmap | get_pixmap (QString str) |
| void | setGlobalTimeMode (TimeMode mode) |
Variables | |
| std::array< QString, 5 > | arrow_name |
| TimeMode | globalTimeMode = TimeMode::Bars |
Function Documentation
◆ addonArchitecture()
| SCORE_LIB_BASE_EXPORT QString score::addonArchitecture | ( | ) |
addonArchitecture
- Returns
- Architecture for the system score is compiled for.
◆ component()
| T & score::component | ( | const score::Components & | c | ) |
component Fetch a Component from Components by type
- Returns
- The component.
The component must have a member static const constexpr bool is_unique = true in order to use this function.
This guarantees that there will be a single component of a given type in the Components.
◆ findComponent()
|
noexcept |
findComponent Tryies to fetch a Component from Components by type.
This works similarly to components ; instead of aborting, it returns a null pointer if the component does not exist.
- See also
- components
◆ locateFilePath()
|
noexcept |
Will also look where the save file is located. TODO in the future also look in a "common" library folder.
◆ marshall()
| auto score::marshall | ( | const Object & | obj | ) |
marshall Serializes a single object
- Parameters
-
obj The object to serialize.
This will create the relevant serialization datatype for Type. For instance, a QByteArray if it is DataStream and a QJSonObject if it is JSONObject
◆ newProcessedFilePath()
| QString score::newProcessedFilePath | ( | const QString & | sourceFile, |
| const QDir & | destination | ||
| ) |
Obtains a new file name in the project folder to save a processed file.
e.g. if the source file is /tmp/foo.wav, the output may be
/home/myself/Documents/My score project/Processed/foo-0003.wav
◆ relativizeFilePath()
|
noexcept |
Will try to convert an absolute path in a relative path from the document's point of view
Variable Documentation
◆ arrow_name
| std::array<QString, 5> score::arrow_name |