Skip to content

Commit

Permalink
Rebranding namespaces
Browse files Browse the repository at this point in the history
  • Loading branch information
rerdavies committed Oct 30, 2023
1 parent bc10d17 commit c7b8ca4
Show file tree
Hide file tree
Showing 207 changed files with 333 additions and 333 deletions.
2 changes: 1 addition & 1 deletion assets/com.twoplay.lv2cairo-plugin.desktop
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ NoDisplay=true
Exec=/not-applicable
GenericName[en_CA]=Lv2 Plugin
GenericName=Lv2 Plugin
Icon=com.twoplay.lv2cairo.plugin
Icon=lv2c.github.io.lv2cairo.plugin
MimeType=
Name[en_CA]=Lv2 Plugin
Name=Lv2 Plugin
Expand Down
8 changes: 4 additions & 4 deletions bin/install_app_icons
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
sudo cp -T assets/oo-icon.svg /usr/share/icons/hicolor/symbolic/apps/com.twoplay.lv2cairo-plugin-symbolic.svg
sudo cp -T assets/oo-icon.svg /usr/share/icons/hicolor/scalable/apps/com.twoplay.lv2cairo-plugin.svg
sudo cp -T assets/oo-icon.svg /usr/share/icons/hicolor/symbolic/apps/lv2c.github.io-plugin-symbolic.svg
sudo cp -T assets/oo-icon.svg /usr/share/icons/hicolor/scalable/apps/lv2c.github.io-plugin.svg
#sudo cp -T assets/oo-icon.png /usr/share/icons//breeze-dark/apps/48/cairotestmain.png
sudo touch /usr/share/icons/hicolor
sudo touch /usr/share/icons/breeze-dark
xdg-desktop-menu uninstall assets/com.twoplay.lv2cairo-plugin.desktop
xdg-desktop-menu install assets/com.twoplay.lv2cairo-plugin.desktop
xdg-desktop-menu uninstall assets/lv2c.github.io-plugin.desktop
xdg-desktop-menu install assets/lv2c.github.io-plugin.desktop
xdg-desktop-menu forceupdate
8 changes: 4 additions & 4 deletions src/generate_lv2c_plugin_info/ClassFileWriter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#include "lv2c_ui/Lv2Units.hpp"

using namespace std;
using namespace lvtk::ui;
using namespace lv2c::ui;

template <typename T>
std::string
Expand Down Expand Up @@ -239,20 +239,20 @@ void ClassFileWriter::Write(const std::shared_ptr<Lv2PluginInfo> pluginInfo)
Indent();
}
{
s << Tab() << "class " << className << ": public lvtk::ui::Lv2PluginInfo"
s << Tab() << "class " << className << ": public lv2c::ui::Lv2PluginInfo"
<< "{" << endl;
s << Tab() << "public:" << endl;
Indent();
{
s << Tab() << "using super=lvtk::ui::Lv2PluginInfo;" << endl;
s << Tab() << "using super=lv2c::ui::Lv2PluginInfo;" << endl;
s << Tab() << "using ptr=std::shared_ptr<" << className << ">;" << endl;
s << Tab() << "static ptr Create() { return std::make_shared<" << className << ">(); }" << endl;
s << endl;

s << Tab() << className << "() {" << endl;
Indent();
{
s << Tab() << "using namespace lvtk::ui;" << endl;
s << Tab() << "using namespace lv2c::ui;" << endl;
s << endl;

WRITE_PROPERTY(pluginInfo, uri)
Expand Down
8 changes: 4 additions & 4 deletions src/generate_lv2c_plugin_info/ClassFileWriter.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@
#include <memory>
#include "lv2c_ui/Lv2PluginInfo.hpp"

using namespace lvtk::ui;
using namespace lv2c::ui;

class ClassFileWriter {
public:

ClassFileWriter(std::ostream&s, const std::string &className, std::string&nameSpace): s(s),className(className),nameSpace(nameSpace) { }
using Lv2PluginInfo = lvtk::ui::Lv2PluginInfo;
using Lv2PortInfo = lvtk::ui::Lv2PortInfo;
using PiPedalUI = lvtk::ui::PiPedalUI;
using Lv2PluginInfo = lv2c::ui::Lv2PluginInfo;
using Lv2PortInfo = lv2c::ui::Lv2PortInfo;
using PiPedalUI = lv2c::ui::PiPedalUI;

void Write(const std::shared_ptr<Lv2PluginInfo> pluginInfo);
private:
Expand Down
2 changes: 1 addition & 1 deletion src/generate_lv2c_plugin_info/LilvPiPedalUI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
#include "lv2c_ui/MimeTypes.hpp"


using namespace lvtk::ui;
using namespace lv2c::ui;
using namespace lv2;
using namespace std;

Expand Down
2 changes: 1 addition & 1 deletion src/generate_lv2c_plugin_info/LilvPiPedalUI.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@



namespace lvtk::ui
namespace lv2c::ui
{

class LilvUiFileType : public UiFileType
Expand Down
2 changes: 1 addition & 1 deletion src/generate_lv2c_plugin_info/LilvPluginInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#include <string.h>


using namespace lvtk::ui;
using namespace lv2c::ui;
using namespace lv2;

static constexpr const char *RDFS__comment = "http://www.w3.org/2000/01/rdf-schema#"
Expand Down
6 changes: 3 additions & 3 deletions src/generate_lv2c_plugin_info/LilvPluginInfo.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,18 +23,18 @@
#include <lilv/lilv.h>


namespace lvtk::ui {
namespace lv2c::ui {

// Provides construction of Lv2PluginInfo from lilv.

class LilvPortInfo: public lvtk::ui::Lv2PortInfo {
class LilvPortInfo: public lv2c::ui::Lv2PortInfo {
public:
LilvPortInfo(LilvWorld*pWorld,const LilvPlugin *pPlugin, const LilvPort *pPort);

private:
Lv2BufferType GetBufferType(const std::string&buffer_type);
};
class LilvPluginInfo: public lvtk::ui::Lv2PluginInfo {
class LilvPluginInfo: public lv2c::ui::Lv2PluginInfo {
public:
LilvPluginInfo(LilvWorld *pWorld, const LilvPlugin *pPlugin);
private:
Expand Down
2 changes: 1 addition & 1 deletion src/generate_lv2c_plugin_info/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
using namespace std;
using namespace lv2;
using namespace twoplay;
using namespace lvtk::ui;
using namespace lv2c::ui;

class cleanup
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/IcuString.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
#include <sstream>

using namespace icu;
using namespace lvtk;
using namespace lv2c;

IcuString::~IcuString()
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/JsonIo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include <sstream>
#include <cmath>

using namespace lvtk;
using namespace lv2c;


static constexpr uint16_t UTF16_SURROGATE_1_BASE = 0xD800U;
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/JsonVariant.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
#include <memory>
#include <sstream>

using namespace lvtk;
using namespace lv2c;

json_variant::~json_variant()
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cAnimator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "lv2c/Lv2cAnimator.hpp"
#include "lv2c/Lv2cWindow.hpp"

using namespace lvtk;
using namespace lv2c;

Lv2cAnimator::~Lv2cAnimator()
{
Expand Down
16 changes: 8 additions & 8 deletions src/lv2c/Lv2cBindingProperty.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@
#include "lv2c/Lv2cObject.hpp"
#include <atomic>

using namespace lvtk;
using namespace lv2c;

std::atomic<uint64_t> gNextHandle;

// explicit specializations of bindings..
namespace lvtk
namespace lv2c
{
template class Observable<double>;
template class Lv2cBindingProperty<double>;
Expand Down Expand Up @@ -63,16 +63,16 @@ MapRangeBindingTransform::MapRangeBindingTransform(double sourceMinVal, double s
{
}

uint64_t lvtk::implementation::nextHandle()
uint64_t lv2c::implementation::nextHandle()
{
return ++gNextHandle;
}

uint64_t lvtk::implementation::handleCount = 0;
uint64_t lvtk::implementation::bindingRecordCount = 0;
uint64_t lvtk::implementation::observerLinkCount = 0;
uint64_t lv2c::implementation::handleCount = 0;
uint64_t lv2c::implementation::bindingRecordCount = 0;
uint64_t lv2c::implementation::observerLinkCount = 0;

namespace lvtk::implementation
namespace lv2c::implementation
{
ObserverLink::ObserverLink()
{
Expand Down Expand Up @@ -131,4 +131,4 @@ namespace lvtk::implementation
}
}

} // namespace lvtk::implementation
} // namespace lv2c::implementation
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cButtonBaseElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

#include "lv2c/Lv2cDrawingContext.hpp"

using namespace lvtk;
using namespace lv2c;

Lv2cButtonBaseElement::Lv2cButtonBaseElement()
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cButtonElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
#define XK_MISCELLANY
#include "X11/keysymdef.h"

using namespace lvtk;
using namespace lv2c;



Expand Down
10 changes: 5 additions & 5 deletions src/lv2c/Lv2cCieColors.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@
#include "lv2c/Lv2cCieColors.hpp"
#include <cassert>

using namespace lvtk;
using namespace lv2c;

Lv2cCieXyz lvtk::D65Illuminant{95.0489f, 100.0f, 108.8840f};
Lv2cCieXyz lvtk::D50Illuminant{96.4212f, 100.0f, 82.5188f};
Lv2cCieXyz lv2c::D65Illuminant{95.0489f, 100.0f, 108.8840f};
Lv2cCieXyz lv2c::D50Illuminant{96.4212f, 100.0f, 82.5188f};

Lv2cCieXyz::Lv2cCieXyz(float x, float y, float z)
: x(x), y(y), z(z)
Expand Down Expand Up @@ -259,12 +259,12 @@ Lv2cCieLab::Lv2cCieLab(const Lv2cColor&color, const Lv2cCieXyz&illuminant)
}


double lvtk::CieColorDifference(const Lv2cColor& color_1, const Lv2cColor& color_2)
double lv2c::CieColorDifference(const Lv2cColor& color_1, const Lv2cColor& color_2)
{
return CieColorDifference(Lv2cCieLab(color_1),Lv2cCieLab(color_2));
}

double lvtk::CieColorDifference(const Lv2cCieLab& color_1, const Lv2cCieLab& color_2)
double lv2c::CieColorDifference(const Lv2cCieLab& color_1, const Lv2cCieLab& color_2)
{
// Copyright (c) 2018 Yuki Koyama
//
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cContainerElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

#include "lv2c/Lv2cContainerElement.hpp"

using namespace lvtk;
using namespace lv2c;

void Lv2cContainerElement::AddChild(std::shared_ptr<Lv2cElement> child)
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cDamageList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "lv2c/Lv2cDamageList.hpp"
#include <cmath>

using namespace lvtk;
using namespace lv2c;


int64_t Lv2cDamageList::Width() const
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cDbVuElement.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "lv2c/Lv2cDbVuElement.hpp"
#include "lv2c/Lv2cWindow.hpp"

using namespace lvtk;
using namespace lv2c;

using namespace std::chrono;
constexpr milliseconds HOLD_TIME = 2000ms;
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cDialBaseElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "lv2c/Lv2cDialBaseElement.hpp"
#include "lv2c/Lv2cWindow.hpp"

using namespace lvtk;
using namespace lv2c;

Lv2cDialBaseElement::Lv2cDialBaseElement()
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cDialElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "lv2c/Lv2cDialElement.hpp"
#include "lv2c/Lv2cWindow.hpp"

using namespace lvtk;
using namespace lv2c;

Lv2cDialElement::Lv2cDialElement()
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "lv2c/Lv2cDialog.hpp"
#include "Lv2cX11Window.hpp"

using namespace lvtk;
using namespace lv2c;

Lv2cDialog::~Lv2cDialog()
{
Expand Down
4 changes: 2 additions & 2 deletions src/lv2c/Lv2cDrawingContext.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <numbers>
#include "ss.hpp"

using namespace lvtk;
using namespace lv2c;

Lv2cPattern Lv2cPattern::radial_gradient(double cx, double cy, double radius, const std::vector<Lv2cColorStop> &colorStops)
{
Expand Down Expand Up @@ -192,7 +192,7 @@ Lv2cSurface Lv2cSurface::create_from_png(const std::string &filename)
case cairo_status_t::x: \
return #x;

const std::string lvtk::Lv2cStatusMessage(cairo_status_t status)
const std::string lv2c::Lv2cStatusMessage(cairo_status_t status)
{
switch (status)
{
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cDropShadowElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#include <numbers>
#include "lv2c/Lv2cWindow.hpp"

using namespace lvtk;
using namespace lv2c;

static double ShadowFn(int x_, int y_, int radius)
{
Expand Down
12 changes: 6 additions & 6 deletions src/lv2c/Lv2cDropdownElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@

#include <chrono>

using namespace lvtk;
using namespace lv2c;

namespace lvtk::implementation
namespace lv2c::implementation
{
class DropdownItemLayoutElement : public Lv2cContainerElement
{
Expand Down Expand Up @@ -157,7 +157,7 @@ namespace lvtk::implementation
}
}

using namespace lvtk::implementation;
using namespace lv2c::implementation;

Lv2cSize DropdownItemLayoutElement::MeasureClient(Lv2cSize clientConstraint, Lv2cSize clientAvailable, Lv2cDrawingContext &context)
{
Expand Down Expand Up @@ -406,14 +406,14 @@ bool Lv2cDropdownItem::operator==(const Lv2cDropdownItem &other) const
return itemId == other.itemId && separator == other.separator && svgIcon == other.svgIcon && text == other.text;
}

lvtk::Lv2cDropdownItem::Lv2cDropdownItem() : itemId(INVALID_SELECTION_ID), separator(false) {}
lv2c::Lv2cDropdownItem::Lv2cDropdownItem() : itemId(INVALID_SELECTION_ID), separator(false) {}

lvtk::Lv2cDropdownItem::Lv2cDropdownItem(selection_id_t itemId, const std::string &text)
lv2c::Lv2cDropdownItem::Lv2cDropdownItem(selection_id_t itemId, const std::string &text)
: itemId(itemId), text(text), separator(false)
{
}

lvtk::Lv2cDropdownItem::Lv2cDropdownItem(selection_id_t itemId, const std::string &text, const std::string &svgIcon)
lv2c::Lv2cDropdownItem::Lv2cDropdownItem(selection_id_t itemId, const std::string &text, const std::string &svgIcon)
: itemId(itemId), text(text), svgIcon(svgIcon), separator(false)
{
}
Expand Down
2 changes: 1 addition & 1 deletion src/lv2c/Lv2cDropdownItemElement.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

#include "lv2c/Lv2cDropdownItemElement.hpp"

using namespace lvtk;
using namespace lv2c;

#include "lv2c/Lv2cTypographyElement.hpp"
#include "lv2c/Lv2cSvgElement.hpp"
Expand Down
Loading

0 comments on commit c7b8ca4

Please sign in to comment.