mirror of
https://github.com/vczh-libraries/Release.git
synced 2026-05-22 15:22:23 +08:00
Update release
This commit is contained in:
+297
-112
@@ -58,6 +58,198 @@ namespace gaclib_controls
|
||||
}
|
||||
}
|
||||
|
||||
using ImageCreationMap = remoteprotocol::ArrayMap<vint, remoteprotocol::ImageCreation, &remoteprotocol::ImageCreation::id>;
|
||||
using ElementDescMap = Dictionary<vint, remoteprotocol::UnitTest_ElementDescVariant>;
|
||||
|
||||
Ptr<GuiImageFrameElement> CreateImageElement(const remoteprotocol::ElementDesc_ImageFrame& desc, Ptr<ImageCreationMap> imageCreations)
|
||||
{
|
||||
auto element = Ptr(GuiImageFrameElement::Create());
|
||||
element->SetAlignments(GetAlignment(desc.horizontalAlignment), GetAlignment(desc.verticalAlignment));
|
||||
element->SetStretch(desc.stretch);
|
||||
element->SetEnabled(desc.enabled);
|
||||
|
||||
if (desc.imageId)
|
||||
{
|
||||
vint index = imageCreations->Keys().IndexOf(desc.imageId.Value());
|
||||
if (index != -1)
|
||||
{
|
||||
auto binary = imageCreations->Values()[index].imageData;
|
||||
binary->SeekFromBegin(0);
|
||||
element->SetImage(GetCurrentController()->ImageService()->CreateImageFromStream(*binary.Obj()), desc.imageFrame);
|
||||
}
|
||||
}
|
||||
|
||||
return element;
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
GuiGraphicsParagraphWrapperElement
|
||||
***********************************************************************/
|
||||
|
||||
class GuiGraphicsParagraphWrapperElement
|
||||
: public Object
|
||||
, public IGuiGraphicsElement
|
||||
, protected IGuiGraphicsRenderer
|
||||
, protected IGuiGraphicsRendererFactory
|
||||
, protected IGuiGraphicsParagraphCallback
|
||||
{
|
||||
protected:
|
||||
remoteprotocol::ElementDesc_DocumentParagraphFull desc;
|
||||
Ptr<ElementDescMap> elementDescs;
|
||||
Ptr<ImageCreationMap> imageCreations;
|
||||
|
||||
Ptr<IGuiGraphicsParagraph> paragraph;
|
||||
GuiGraphicsComposition* ownerComposition = nullptr;
|
||||
IGuiGraphicsRenderTarget* renderTarget = nullptr;
|
||||
|
||||
void SetOwnerComposition(GuiGraphicsComposition* _ownerComposition) override
|
||||
{
|
||||
ownerComposition = _ownerComposition;
|
||||
}
|
||||
|
||||
public:
|
||||
|
||||
GuiGraphicsParagraphWrapperElement(const remoteprotocol::ElementDesc_DocumentParagraphFull& _desc, Ptr<ElementDescMap> _elementDescs, Ptr<ImageCreationMap> _imageCreations)
|
||||
:desc(_desc)
|
||||
, elementDescs(_elementDescs)
|
||||
, imageCreations(_imageCreations)
|
||||
{
|
||||
}
|
||||
|
||||
IGuiGraphicsRenderer* GetRenderer() override
|
||||
{
|
||||
return this;
|
||||
}
|
||||
|
||||
GuiGraphicsComposition* GetOwnerComposition() override
|
||||
{
|
||||
return ownerComposition;
|
||||
}
|
||||
|
||||
protected:
|
||||
|
||||
IGuiGraphicsRendererFactory* GetFactory() override
|
||||
{
|
||||
return this;
|
||||
}
|
||||
|
||||
void Initialize(IGuiGraphicsElement* element) override
|
||||
{
|
||||
}
|
||||
|
||||
void Finalize() override
|
||||
{
|
||||
}
|
||||
|
||||
void SetRenderTarget(IGuiGraphicsRenderTarget* _renderTarget) override
|
||||
{
|
||||
if (renderTarget != _renderTarget)
|
||||
{
|
||||
renderTarget = _renderTarget;
|
||||
paragraph = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void Render(Rect bounds) override
|
||||
{
|
||||
if (!renderTarget) return;
|
||||
if (!paragraph)
|
||||
{
|
||||
auto text = desc.paragraph.text ? desc.paragraph.text.Value() : WString::Empty;
|
||||
paragraph = GetGuiGraphicsResourceManager()->GetLayoutProvider()->CreateParagraph(text, renderTarget, this);
|
||||
|
||||
paragraph->SetWrapLine(desc.paragraph.wrapLine);
|
||||
paragraph->SetMaxWidth(desc.paragraph.maxWidth);
|
||||
paragraph->SetParagraphAlignment(GetAlignment(desc.paragraph.alignment));
|
||||
|
||||
if (desc.paragraph.runsDiff)
|
||||
{
|
||||
for (auto run : *desc.paragraph.runsDiff.Obj())
|
||||
{
|
||||
auto length = run.caretEnd - run.caretBegin;
|
||||
if (length <= 0) continue;
|
||||
|
||||
run.props.Apply(Overloading(
|
||||
[&](const remoteprotocol::DocumentTextRunProperty& textProp)
|
||||
{
|
||||
paragraph->SetFont(run.caretBegin, length, textProp.fontProperties.fontFamily);
|
||||
paragraph->SetSize(run.caretBegin, length, textProp.fontProperties.size);
|
||||
|
||||
IGuiGraphicsParagraph::TextStyle style = (IGuiGraphicsParagraph::TextStyle)0;
|
||||
if (textProp.fontProperties.bold) style = (IGuiGraphicsParagraph::TextStyle)((vint)style | IGuiGraphicsParagraph::Bold);
|
||||
if (textProp.fontProperties.italic) style = (IGuiGraphicsParagraph::TextStyle)((vint)style | IGuiGraphicsParagraph::Italic);
|
||||
if (textProp.fontProperties.underline) style = (IGuiGraphicsParagraph::TextStyle)((vint)style | IGuiGraphicsParagraph::Underline);
|
||||
if (textProp.fontProperties.strikeline) style = (IGuiGraphicsParagraph::TextStyle)((vint)style | IGuiGraphicsParagraph::Strikeline);
|
||||
paragraph->SetStyle(run.caretBegin, length, style);
|
||||
|
||||
paragraph->SetColor(run.caretBegin, length, textProp.textColor);
|
||||
paragraph->SetBackgroundColor(run.caretBegin, length, textProp.backgroundColor);
|
||||
},
|
||||
[&](const remoteprotocol::DocumentInlineObjectRunProperty& inlineProp)
|
||||
{
|
||||
IGuiGraphicsParagraph::InlineObjectProperties properties;
|
||||
properties.size = inlineProp.size;
|
||||
properties.baseline = inlineProp.baseline;
|
||||
properties.breakCondition = inlineProp.breakCondition;
|
||||
properties.callbackId = inlineProp.callbackId;
|
||||
if (inlineProp.backgroundElementId != -1)
|
||||
{
|
||||
auto& desc = elementDescs->Get(inlineProp.backgroundElementId).Get<remoteprotocol::ElementDesc_ImageFrame>();
|
||||
auto element = CreateImageElement(desc, imageCreations);
|
||||
properties.backgroundImage = element;
|
||||
}
|
||||
paragraph->SetInlineObject(run.caretBegin, length, properties);
|
||||
}
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
if (desc.caret)
|
||||
{
|
||||
auto& caret = desc.caret.Value();
|
||||
paragraph->OpenCaret(caret.caret, caret.caretColor, caret.frontSide);
|
||||
}
|
||||
}
|
||||
paragraph->Render(bounds);
|
||||
}
|
||||
|
||||
void OnElementStateChanged() override
|
||||
{
|
||||
}
|
||||
|
||||
Size GetMinSize() override
|
||||
{
|
||||
return {};
|
||||
}
|
||||
|
||||
protected:
|
||||
|
||||
IGuiGraphicsRenderer* Create() override
|
||||
{
|
||||
CHECK_FAIL(L"Not Implemented!");
|
||||
}
|
||||
|
||||
protected:
|
||||
|
||||
Size OnRenderInlineObject(vint callbackId, Rect location) override
|
||||
{
|
||||
if (!desc.paragraph.runsDiff) return {};
|
||||
Size result;
|
||||
bool found = false;
|
||||
for (auto&& run : *desc.paragraph.runsDiff.Obj())
|
||||
{
|
||||
if (auto props = run.props.TryGet<remoteprotocol::DocumentInlineObjectRunProperty>())
|
||||
{
|
||||
if (props->callbackId == callbackId)
|
||||
{
|
||||
return props->size;
|
||||
}
|
||||
}
|
||||
}
|
||||
return {};
|
||||
}
|
||||
};
|
||||
|
||||
void InstallDom(
|
||||
const remoteprotocol::UnitTest_RenderingTrace& trace,
|
||||
const remoteprotocol::UnitTest_RenderingFrame& frame,
|
||||
@@ -124,128 +316,120 @@ namespace gaclib_controls
|
||||
switch (trace.createdElements->Get(dom->content.element.Value()))
|
||||
{
|
||||
case remoteprotocol::RendererType::FocusRectangle:
|
||||
{
|
||||
auto element = Ptr(GuiFocusRectangleElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
}
|
||||
break;
|
||||
{
|
||||
auto element = Ptr(GuiFocusRectangleElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::Raw:
|
||||
// Do Nothing
|
||||
break;
|
||||
case remoteprotocol::RendererType::SolidBorder:
|
||||
{
|
||||
auto element = Ptr(GuiSolidBorderElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SolidBorder>();
|
||||
|
||||
element->SetColor(desc.borderColor);
|
||||
element->SetShape(desc.shape);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::SinkBorder:
|
||||
{
|
||||
auto element = Ptr(Gui3DBorderElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SinkBorder>();
|
||||
|
||||
element->SetColors(desc.leftTopColor, desc.rightBottomColor);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::SinkSplitter:
|
||||
{
|
||||
auto element = Ptr(Gui3DSplitterElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SinkSplitter>();
|
||||
|
||||
element->SetColors(desc.leftTopColor, desc.rightBottomColor);
|
||||
element->SetDirection(desc.direction);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::SolidBackground:
|
||||
{
|
||||
auto element = Ptr(GuiSolidBackgroundElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SolidBackground>();
|
||||
|
||||
element->SetColor(desc.backgroundColor);
|
||||
element->SetShape(desc.shape);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::GradientBackground:
|
||||
{
|
||||
auto element = Ptr(GuiGradientBackgroundElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_GradientBackground>();
|
||||
|
||||
element->SetColors(desc.leftTopColor, desc.rightBottomColor);
|
||||
element->SetDirection(desc.direction);
|
||||
element->SetShape(desc.shape);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::InnerShadow:
|
||||
{
|
||||
auto element = Ptr(GuiInnerShadowElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_InnerShadow>();
|
||||
|
||||
element->SetColor(desc.shadowColor);
|
||||
element->SetThickness(desc.thickness);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::SolidLabel:
|
||||
{
|
||||
auto element = Ptr(GuiSolidLabelElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SolidLabel>();
|
||||
|
||||
element->SetColor(desc.textColor);
|
||||
element->SetAlignments(GetAlignment(desc.horizontalAlignment), GetAlignment(desc.verticalAlignment));
|
||||
element->SetWrapLine(desc.wrapLine);
|
||||
element->SetWrapLineHeightCalculation(desc.wrapLineHeightCalculation);
|
||||
element->SetEllipse(desc.ellipse);
|
||||
element->SetMultiline(desc.multiline);
|
||||
element->SetFont(desc.font.Value());
|
||||
element->SetText(desc.text.Value());
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::Polygon:
|
||||
{
|
||||
auto element = Ptr(GuiPolygonElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_Polygon>();
|
||||
|
||||
element->SetSize(desc.size);
|
||||
element->SetBorderColor(desc.borderColor);
|
||||
element->SetBackgroundColor(desc.backgroundColor);
|
||||
|
||||
if (desc.points && desc.points->Count() > 0)
|
||||
{
|
||||
element->SetPoints(&desc.points->Get(0), desc.points->Count());
|
||||
auto element = Ptr(GuiSolidBorderElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SolidBorder>();
|
||||
|
||||
element->SetColor(desc.borderColor);
|
||||
element->SetShape(desc.shape);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::ImageFrame:
|
||||
{
|
||||
auto element = Ptr(GuiImageFrameElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_ImageFrame>();
|
||||
|
||||
element->SetAlignments(GetAlignment(desc.horizontalAlignment), GetAlignment(desc.verticalAlignment));
|
||||
element->SetStretch(desc.stretch);
|
||||
element->SetEnabled(desc.enabled);
|
||||
|
||||
if (desc.imageId)
|
||||
break;
|
||||
case remoteprotocol::RendererType::SinkBorder:
|
||||
{
|
||||
vint index = trace.imageCreations->Keys().IndexOf(desc.imageId.Value());
|
||||
if (index != -1)
|
||||
auto element = Ptr(Gui3DBorderElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SinkBorder>();
|
||||
|
||||
element->SetColors(desc.leftTopColor, desc.rightBottomColor);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::SinkSplitter:
|
||||
{
|
||||
auto element = Ptr(Gui3DSplitterElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SinkSplitter>();
|
||||
|
||||
element->SetColors(desc.leftTopColor, desc.rightBottomColor);
|
||||
element->SetDirection(desc.direction);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::SolidBackground:
|
||||
{
|
||||
auto element = Ptr(GuiSolidBackgroundElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SolidBackground>();
|
||||
|
||||
element->SetColor(desc.backgroundColor);
|
||||
element->SetShape(desc.shape);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::GradientBackground:
|
||||
{
|
||||
auto element = Ptr(GuiGradientBackgroundElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_GradientBackground>();
|
||||
|
||||
element->SetColors(desc.leftTopColor, desc.rightBottomColor);
|
||||
element->SetDirection(desc.direction);
|
||||
element->SetShape(desc.shape);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::InnerShadow:
|
||||
{
|
||||
auto element = Ptr(GuiInnerShadowElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_InnerShadow>();
|
||||
|
||||
element->SetColor(desc.shadowColor);
|
||||
element->SetThickness(desc.thickness);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::SolidLabel:
|
||||
{
|
||||
auto element = Ptr(GuiSolidLabelElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_SolidLabel>();
|
||||
|
||||
element->SetColor(desc.textColor);
|
||||
element->SetAlignments(GetAlignment(desc.horizontalAlignment), GetAlignment(desc.verticalAlignment));
|
||||
element->SetWrapLine(desc.wrapLine);
|
||||
element->SetWrapLineHeightCalculation(desc.wrapLineHeightCalculation);
|
||||
element->SetEllipse(desc.ellipse);
|
||||
element->SetMultiline(desc.multiline);
|
||||
element->SetFont(desc.font.Value());
|
||||
element->SetText(desc.text.Value());
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::Polygon:
|
||||
{
|
||||
auto element = Ptr(GuiPolygonElement::Create());
|
||||
bounds->SetOwnedElement(element);
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_Polygon>();
|
||||
|
||||
element->SetSize(desc.size);
|
||||
element->SetBorderColor(desc.borderColor);
|
||||
element->SetBackgroundColor(desc.backgroundColor);
|
||||
|
||||
if (desc.points && desc.points->Count() > 0)
|
||||
{
|
||||
auto binary = trace.imageCreations->Values()[index].imageData;
|
||||
binary->SeekFromBegin(0);
|
||||
element->SetImage(GetCurrentController()->ImageService()->CreateImageFromStream(*binary.Obj()), desc.imageFrame);
|
||||
element->SetPoints(&desc.points->Get(0), desc.points->Count());
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
break;
|
||||
case remoteprotocol::RendererType::ImageFrame:
|
||||
{
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_ImageFrame>();
|
||||
auto element = CreateImageElement(desc, trace.imageCreations);
|
||||
bounds->SetOwnedElement(element);
|
||||
}
|
||||
break;
|
||||
case remoteprotocol::RendererType::DocumentParagraph:
|
||||
{
|
||||
auto& desc = frame.elements->Get(dom->content.element.Value()).Get<remoteprotocol::ElementDesc_DocumentParagraphFull>();
|
||||
auto element = Ptr(new GuiGraphicsParagraphWrapperElement(desc, frame.elements, trace.imageCreations));
|
||||
bounds->SetOwnedElement(element);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
CHECK_FAIL(L"This element is not supported yet.");
|
||||
break;
|
||||
@@ -465,6 +649,7 @@ namespace gaclib_controls
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
.\SOURCE\GUIUNITTESTSNAPSHOTVIEWER.CPP
|
||||
***********************************************************************/
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
+224
-813
File diff suppressed because it is too large
Load Diff
+416
-219
File diff suppressed because it is too large
Load Diff
+86
-19
@@ -10069,6 +10069,13 @@ Helper Functions
|
||||
#undef ERROR_MESSAGE_PREFIX
|
||||
}
|
||||
|
||||
template<typename T, typename ...TArgs>
|
||||
T* FindObjectByName(GuiInstanceRootObject* rootObject, const WString& firstName, TArgs&& ...remains)
|
||||
{
|
||||
auto firstObject = FindObjectByName<GuiInstanceRootObject>(rootObject, firstName);
|
||||
return FindObjectByName<T>(firstObject, std::forward<TArgs&&>(remains)...);
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
requires(std::is_base_of_v<controls::GuiControl, T>)
|
||||
T* TryFindControlByText(GuiControl* rootObject, const WString& text)
|
||||
@@ -11089,7 +11096,7 @@ Dialogs
|
||||
class GuiFileDialogBase abstract : public GuiDialogBase, public Description<GuiFileDialogBase>
|
||||
{
|
||||
protected:
|
||||
WString filter = L"All Files (*.*)|*.*";
|
||||
WString filter = L"All Files (*.*)|*";
|
||||
vint filterIndex = 0;
|
||||
bool enabledPreview = false;
|
||||
WString title;
|
||||
@@ -11630,12 +11637,17 @@ Rich Content Document (run)
|
||||
class DocumentInlineObjectRun : public DocumentContentRun, public Description<DocumentInlineObjectRun>
|
||||
{
|
||||
public:
|
||||
/// <summary>Size of the inline object.</summary>
|
||||
Size size;
|
||||
/// <summary>Baseline of the inline object.</summary>
|
||||
vint baseline;
|
||||
/// <summary>Size of the inline object. When it is empty, it either becomes the size of the image, or (1,1) if there is no image.</summary>
|
||||
Nullable<Size> sizeOverride;
|
||||
/// <summary>Baseline of the inline object. When it is -1, it becomes sizeOverride.Value().y</summary>
|
||||
vint baseline = -1;
|
||||
|
||||
DocumentInlineObjectRun():baseline(-1){}
|
||||
DocumentInlineObjectRun(){}
|
||||
|
||||
virtual Size GetSize()
|
||||
{
|
||||
return sizeOverride ? sizeOverride.Value() : Size(1, 1);
|
||||
}
|
||||
};
|
||||
|
||||
/// <summary>Pepresents a image run.</summary>
|
||||
@@ -11647,11 +11659,20 @@ Rich Content Document (run)
|
||||
/// <summary>The image.</summary>
|
||||
Ptr<INativeImage> image;
|
||||
/// <summary>The frame index.</summary>
|
||||
vint frameIndex;
|
||||
vint frameIndex = 0;
|
||||
/// <summary>The image source string.</summary>
|
||||
WString source;
|
||||
|
||||
DocumentImageRun():frameIndex(0){}
|
||||
DocumentImageRun(){}
|
||||
|
||||
Size GetSize() override
|
||||
{
|
||||
if (image && !sizeOverride && 0 <= frameIndex && frameIndex < image->GetFrameCount())
|
||||
{
|
||||
return image->GetFrame(frameIndex)->GetSize();
|
||||
}
|
||||
return DocumentInlineObjectRun::GetSize();
|
||||
}
|
||||
|
||||
WString GetRepresentationText()override{return RepresentationText;}
|
||||
void Accept(IVisitor* visitor)override{visitor->Visit(this);}
|
||||
@@ -20835,9 +20856,12 @@ namespace vl::presentation::remoteprotocol
|
||||
struct DocumentInlineObjectRunProperty;
|
||||
struct DocumentRun;
|
||||
struct ElementDesc_DocumentParagraph;
|
||||
struct UpdateElement_DocumentParagraphResponse;
|
||||
struct GetCaretRequest;
|
||||
struct GetCaretResponse;
|
||||
struct GetCaretBoundsRequest;
|
||||
struct GetInlineObjectFromPointRequest;
|
||||
struct IsValidCaretRequest;
|
||||
struct OpenCaretRequest;
|
||||
struct RenderInlineObjectRequest;
|
||||
struct RendererCreation;
|
||||
@@ -20851,6 +20875,7 @@ namespace vl::presentation::remoteprotocol
|
||||
struct RenderingDom;
|
||||
struct RenderingDom_Diff;
|
||||
struct RenderingDom_DiffsInOrder;
|
||||
struct ElementDesc_DocumentParagraphFull;
|
||||
struct UnitTest_RenderingFrame;
|
||||
struct UnitTest_RenderingTrace;
|
||||
}
|
||||
@@ -20892,9 +20917,12 @@ namespace vl::presentation::remoteprotocol
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::DocumentInlineObjectRunProperty> { static constexpr const wchar_t* Name = L"DocumentInlineObjectRunProperty"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::DocumentRun> { static constexpr const wchar_t* Name = L"DocumentRun"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph> { static constexpr const wchar_t* Name = L"ElementDesc_DocumentParagraph"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::UpdateElement_DocumentParagraphResponse> { static constexpr const wchar_t* Name = L"UpdateElement_DocumentParagraphResponse"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::GetCaretRequest> { static constexpr const wchar_t* Name = L"GetCaretRequest"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::GetCaretResponse> { static constexpr const wchar_t* Name = L"GetCaretResponse"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::GetCaretBoundsRequest> { static constexpr const wchar_t* Name = L"GetCaretBoundsRequest"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::GetInlineObjectFromPointRequest> { static constexpr const wchar_t* Name = L"GetInlineObjectFromPointRequest"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::IsValidCaretRequest> { static constexpr const wchar_t* Name = L"IsValidCaretRequest"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::OpenCaretRequest> { static constexpr const wchar_t* Name = L"OpenCaretRequest"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::RenderInlineObjectRequest> { static constexpr const wchar_t* Name = L"RenderInlineObjectRequest"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::RendererCreation> { static constexpr const wchar_t* Name = L"RendererCreation"; };
|
||||
@@ -20908,6 +20936,7 @@ namespace vl::presentation::remoteprotocol
|
||||
template<> struct JsonNameHelper<::vl::Ptr<::vl::presentation::remoteprotocol::RenderingDom>> { static constexpr const wchar_t* Name = L"RenderingDom"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::RenderingDom_Diff> { static constexpr const wchar_t* Name = L"RenderingDom_Diff"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::RenderingDom_DiffsInOrder> { static constexpr const wchar_t* Name = L"RenderingDom_DiffsInOrder"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraphFull> { static constexpr const wchar_t* Name = L"ElementDesc_DocumentParagraphFull"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::UnitTest_RenderingFrame> { static constexpr const wchar_t* Name = L"UnitTest_RenderingFrame"; };
|
||||
template<> struct JsonNameHelper<::vl::presentation::remoteprotocol::UnitTest_RenderingTrace> { static constexpr const wchar_t* Name = L"UnitTest_RenderingTrace"; };
|
||||
}
|
||||
@@ -20985,7 +21014,7 @@ namespace vl::presentation::remoteprotocol
|
||||
::vl::presentation::remoteprotocol::ElementDesc_Polygon,
|
||||
::vl::presentation::remoteprotocol::ElementDesc_SolidLabel,
|
||||
::vl::presentation::remoteprotocol::ElementDesc_ImageFrame,
|
||||
::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph
|
||||
::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraphFull
|
||||
>;
|
||||
|
||||
struct FontConfig
|
||||
@@ -21171,8 +21200,15 @@ namespace vl::presentation::remoteprotocol
|
||||
::vl::Ptr<::vl::collections::List<::vl::vint>> removedInlineObjects;
|
||||
};
|
||||
|
||||
struct UpdateElement_DocumentParagraphResponse
|
||||
{
|
||||
::vl::presentation::Size documentSize;
|
||||
::vl::Ptr<::vl::collections::Dictionary<::vl::vint, ::vl::presentation::Rect>> inlineObjectBounds;
|
||||
};
|
||||
|
||||
struct GetCaretRequest
|
||||
{
|
||||
::vl::vint id;
|
||||
::vl::vint caret;
|
||||
::vl::presentation::elements::IGuiGraphicsParagraph::CaretRelativePosition relativePosition;
|
||||
};
|
||||
@@ -21185,12 +21221,26 @@ namespace vl::presentation::remoteprotocol
|
||||
|
||||
struct GetCaretBoundsRequest
|
||||
{
|
||||
::vl::vint id;
|
||||
::vl::vint caret;
|
||||
bool frontSide;
|
||||
};
|
||||
|
||||
struct GetInlineObjectFromPointRequest
|
||||
{
|
||||
::vl::vint id;
|
||||
::vl::presentation::Point point;
|
||||
};
|
||||
|
||||
struct IsValidCaretRequest
|
||||
{
|
||||
::vl::vint id;
|
||||
::vl::vint caret;
|
||||
};
|
||||
|
||||
struct OpenCaretRequest
|
||||
{
|
||||
::vl::vint id;
|
||||
::vl::vint caret;
|
||||
::vl::presentation::Color caretColor;
|
||||
bool frontSide;
|
||||
@@ -21278,6 +21328,12 @@ namespace vl::presentation::remoteprotocol
|
||||
::vl::Ptr<::vl::collections::List<::vl::presentation::remoteprotocol::RenderingDom_Diff>> diffsInOrder;
|
||||
};
|
||||
|
||||
struct ElementDesc_DocumentParagraphFull
|
||||
{
|
||||
::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph paragraph;
|
||||
::vl::Nullable<::vl::presentation::remoteprotocol::OpenCaretRequest> caret;
|
||||
};
|
||||
|
||||
struct UnitTest_RenderingFrame
|
||||
{
|
||||
::vl::vint frameId;
|
||||
@@ -21347,9 +21403,12 @@ namespace vl::presentation::remoteprotocol
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::DocumentInlineObjectRunProperty>(const ::vl::presentation::remoteprotocol::DocumentInlineObjectRunProperty & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::DocumentRun>(const ::vl::presentation::remoteprotocol::DocumentRun & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph>(const ::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::UpdateElement_DocumentParagraphResponse>(const ::vl::presentation::remoteprotocol::UpdateElement_DocumentParagraphResponse & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::GetCaretRequest>(const ::vl::presentation::remoteprotocol::GetCaretRequest & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::GetCaretResponse>(const ::vl::presentation::remoteprotocol::GetCaretResponse & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::GetCaretBoundsRequest>(const ::vl::presentation::remoteprotocol::GetCaretBoundsRequest & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::GetInlineObjectFromPointRequest>(const ::vl::presentation::remoteprotocol::GetInlineObjectFromPointRequest & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::IsValidCaretRequest>(const ::vl::presentation::remoteprotocol::IsValidCaretRequest & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::OpenCaretRequest>(const ::vl::presentation::remoteprotocol::OpenCaretRequest & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::RenderInlineObjectRequest>(const ::vl::presentation::remoteprotocol::RenderInlineObjectRequest & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::RendererCreation>(const ::vl::presentation::remoteprotocol::RendererCreation & value);
|
||||
@@ -21363,6 +21422,7 @@ namespace vl::presentation::remoteprotocol
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::RenderingDom>(const ::vl::presentation::remoteprotocol::RenderingDom & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::RenderingDom_Diff>(const ::vl::presentation::remoteprotocol::RenderingDom_Diff & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::RenderingDom_DiffsInOrder>(const ::vl::presentation::remoteprotocol::RenderingDom_DiffsInOrder & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraphFull>(const ::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraphFull & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::UnitTest_RenderingFrame>(const ::vl::presentation::remoteprotocol::UnitTest_RenderingFrame & value);
|
||||
template<> vl::Ptr<vl::glr::json::JsonNode> ConvertCustomTypeToJson<::vl::presentation::remoteprotocol::UnitTest_RenderingTrace>(const ::vl::presentation::remoteprotocol::UnitTest_RenderingTrace & value);
|
||||
|
||||
@@ -21418,9 +21478,12 @@ namespace vl::presentation::remoteprotocol
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::DocumentInlineObjectRunProperty>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::DocumentInlineObjectRunProperty& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::DocumentRun>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::DocumentRun& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::UpdateElement_DocumentParagraphResponse>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::UpdateElement_DocumentParagraphResponse& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::GetCaretRequest>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::GetCaretRequest& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::GetCaretResponse>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::GetCaretResponse& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::GetCaretBoundsRequest>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::GetCaretBoundsRequest& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::GetInlineObjectFromPointRequest>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::GetInlineObjectFromPointRequest& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::IsValidCaretRequest>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::IsValidCaretRequest& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::OpenCaretRequest>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::OpenCaretRequest& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::RenderInlineObjectRequest>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::RenderInlineObjectRequest& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::RendererCreation>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::RendererCreation& value);
|
||||
@@ -21434,6 +21497,7 @@ namespace vl::presentation::remoteprotocol
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::RenderingDom>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::RenderingDom& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::RenderingDom_Diff>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::RenderingDom_Diff& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::RenderingDom_DiffsInOrder>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::RenderingDom_DiffsInOrder& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraphFull>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraphFull& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::UnitTest_RenderingFrame>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::UnitTest_RenderingFrame& value);
|
||||
template<> void ConvertJsonToCustomType<::vl::presentation::remoteprotocol::UnitTest_RenderingTrace>(vl::Ptr<vl::glr::json::JsonNode> node, ::vl::presentation::remoteprotocol::UnitTest_RenderingTrace& value);
|
||||
|
||||
@@ -21475,14 +21539,14 @@ namespace vl::presentation::remoteprotocol
|
||||
HANDLER(ImageCreated, ::vl::presentation::remoteprotocol::ImageCreation, ::vl::presentation::remoteprotocol::ImageMetadata, REQ, RES, NODROP)\
|
||||
HANDLER(ImageDestroyed, ::vl::vint, void, REQ, NORES, NODROP)\
|
||||
HANDLER(RendererUpdateElement_ImageFrame, ::vl::presentation::remoteprotocol::ElementDesc_ImageFrame, void, REQ, NORES, NODROP)\
|
||||
HANDLER(RendererUpdateElement_DocumentParagraph, ::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph, ::vl::presentation::Size, REQ, RES, NODROP)\
|
||||
HANDLER(RendererUpdateElement_DocumentParagraph, ::vl::presentation::remoteprotocol::ElementDesc_DocumentParagraph, ::vl::presentation::remoteprotocol::UpdateElement_DocumentParagraphResponse, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_GetCaret, ::vl::presentation::remoteprotocol::GetCaretRequest, ::vl::presentation::remoteprotocol::GetCaretResponse, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_GetCaretBounds, ::vl::presentation::remoteprotocol::GetCaretBoundsRequest, ::vl::presentation::Rect, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_GetInlineObjectFromPoint, ::vl::presentation::Point, ::vl::Nullable<::vl::presentation::remoteprotocol::DocumentRun>, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_GetInlineObjectFromPoint, ::vl::presentation::remoteprotocol::GetInlineObjectFromPointRequest, ::vl::Nullable<::vl::presentation::remoteprotocol::DocumentRun>, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_GetNearestCaretFromTextPos, ::vl::presentation::remoteprotocol::GetCaretBoundsRequest, ::vl::vint, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_IsValidCaret, ::vl::vint, bool, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_IsValidCaret, ::vl::presentation::remoteprotocol::IsValidCaretRequest, bool, REQ, RES, NODROP)\
|
||||
HANDLER(DocumentParagraph_OpenCaret, ::vl::presentation::remoteprotocol::OpenCaretRequest, void, REQ, NORES, NODROP)\
|
||||
HANDLER(DocumentParagraph_CloseCaret, void, void, NOREQ, NORES, NODROP)\
|
||||
HANDLER(DocumentParagraph_CloseCaret, ::vl::vint, void, REQ, NORES, NODROP)\
|
||||
HANDLER(RendererCreated, ::vl::Ptr<::vl::collections::List<::vl::presentation::remoteprotocol::RendererCreation>>, void, REQ, NORES, NODROP)\
|
||||
HANDLER(RendererDestroyed, ::vl::Ptr<::vl::collections::List<::vl::vint>>, void, REQ, NORES, NODROP)\
|
||||
HANDLER(RendererBeginRendering, ::vl::presentation::remoteprotocol::ElementBeginRendering, void, REQ, NORES, NODROP)\
|
||||
@@ -21513,7 +21577,6 @@ namespace vl::presentation::remoteprotocol
|
||||
HANDLER(IOKeyDown, ::vl::presentation::NativeWindowKeyInfo, REQ, NODROP)\
|
||||
HANDLER(IOKeyUp, ::vl::presentation::NativeWindowKeyInfo, REQ, NODROP)\
|
||||
HANDLER(IOChar, ::vl::presentation::NativeWindowCharInfo, REQ, NODROP)\
|
||||
HANDLER(DocumentParagraph_RenderInlineObjects, ::vl::Ptr<::vl::collections::List<::vl::presentation::remoteprotocol::RenderInlineObjectRequest>>, REQ, NODROP)\
|
||||
|
||||
#define GACUI_REMOTEPROTOCOL_MESSAGE_REQUEST_TYPES(HANDLER)\
|
||||
HANDLER(::vl::Ptr<::vl::collections::List<::vl::presentation::remoteprotocol::GlobalShortcutKey>>)\
|
||||
@@ -21523,7 +21586,6 @@ namespace vl::presentation::remoteprotocol
|
||||
HANDLER(::vl::WString)\
|
||||
HANDLER(::vl::presentation::NativeRect)\
|
||||
HANDLER(::vl::presentation::NativeSize)\
|
||||
HANDLER(::vl::presentation::Point)\
|
||||
HANDLER(::vl::presentation::VKEY)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::ElementBeginRendering)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::ElementBoundary)\
|
||||
@@ -21540,7 +21602,9 @@ namespace vl::presentation::remoteprotocol
|
||||
HANDLER(::vl::presentation::remoteprotocol::ElementRendering)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::GetCaretBoundsRequest)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::GetCaretRequest)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::GetInlineObjectFromPointRequest)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::ImageCreation)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::IsValidCaretRequest)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::OpenCaretRequest)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::RenderingDom_DiffsInOrder)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::WindowShowing)\
|
||||
@@ -21550,18 +21614,17 @@ namespace vl::presentation::remoteprotocol
|
||||
#define GACUI_REMOTEPROTOCOL_MESSAGE_RESPONSE_TYPES(HANDLER)\
|
||||
HANDLER(::vl::Nullable<::vl::presentation::remoteprotocol::DocumentRun>)\
|
||||
HANDLER(::vl::presentation::Rect)\
|
||||
HANDLER(::vl::presentation::Size)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::ElementMeasurings)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::FontConfig)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::GetCaretResponse)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::ImageMetadata)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::ScreenConfig)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::UpdateElement_DocumentParagraphResponse)\
|
||||
HANDLER(::vl::presentation::remoteprotocol::WindowSizingConfig)\
|
||||
HANDLER(::vl::vint)\
|
||||
HANDLER(bool)\
|
||||
|
||||
#define GACUI_REMOTEPROTOCOL_EVENT_REQUEST_TYPES(HANDLER)\
|
||||
HANDLER(::vl::Ptr<::vl::collections::List<::vl::presentation::remoteprotocol::RenderInlineObjectRequest>>)\
|
||||
HANDLER(::vl::presentation::NativeWindowCharInfo)\
|
||||
HANDLER(::vl::presentation::NativeWindowKeyInfo)\
|
||||
HANDLER(::vl::presentation::NativeWindowMouseInfo)\
|
||||
@@ -21675,6 +21738,7 @@ GuiRemoteGraphicsParagraph
|
||||
vint maxWidth = -1;
|
||||
Alignment paragraphAlignment = Alignment::Left;
|
||||
Size cachedSize = Size(0, 0);
|
||||
Ptr<collections::Dictionary<vint, Rect>> cachedInlineObjectBounds;
|
||||
bool needUpdate = true;
|
||||
vint id = -1;
|
||||
vuint64_t lastRenderedBatchId = 0;
|
||||
@@ -21689,10 +21753,11 @@ GuiRemoteGraphicsParagraph
|
||||
vint NativeTextPosToRemoteTextPos(vint textPos);
|
||||
vint RemoteTextPosToNativeTextPos(vint textPos);
|
||||
bool TryBuildCaretRange(vint start, vint length, CaretRange& range);
|
||||
|
||||
public:
|
||||
bool EnsureRemoteParagraphSynced();
|
||||
void MarkParagraphDirty(bool invalidateSize);
|
||||
|
||||
public:
|
||||
// =============================================================
|
||||
// IGuiGraphicsParagraph
|
||||
// =============================================================
|
||||
@@ -21731,6 +21796,7 @@ GuiRemoteGraphicsParagraph
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
.\PLATFORMPROVIDERS\REMOTE\GUIREMOTEGRAPHICS_IMAGESERVICE.H
|
||||
***********************************************************************/
|
||||
@@ -21932,6 +21998,7 @@ GuiRemoteGraphicsRenderTarget
|
||||
GuiRemoteGraphicsRenderTarget(GuiRemoteController* _remote, GuiHostedController* _hostedController);
|
||||
~GuiRemoteGraphicsRenderTarget();
|
||||
|
||||
void EnsureRequestedRenderersCreated();
|
||||
void OnControllerConnect();
|
||||
void OnControllerDisconnect();
|
||||
|
||||
@@ -21975,7 +22042,6 @@ GuiRemoteGraphicsResourceManager
|
||||
|
||||
void OnControllerConnect();
|
||||
void OnControllerDisconnect();
|
||||
void OnDocumentParagraph_RenderInlineObjects(collections::List<remoteprotocol::RenderInlineObjectRequest>& arguments);
|
||||
|
||||
// =============================================================
|
||||
// IGuiGraphicsResourceManager
|
||||
@@ -21992,6 +22058,7 @@ GuiRemoteGraphicsResourceManager
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
.\PLATFORMPROVIDERS\REMOTE\GUIREMOTEGRAPHICS_BASICELEMENTS.H
|
||||
***********************************************************************/
|
||||
|
||||
+198
-205
File diff suppressed because it is too large
Load Diff
+17
-17
@@ -1636,23 +1636,23 @@ namespace vl::presentation::remoteprotocol
|
||||
enum class ParserStates
|
||||
{
|
||||
RType = 0,
|
||||
RAttributeParameter = 26,
|
||||
RAttribute = 29,
|
||||
REnumMember = 37,
|
||||
REnum = 41,
|
||||
RUnionMember = 48,
|
||||
RUnion = 52,
|
||||
RStructMember = 59,
|
||||
RStructBody = 66,
|
||||
RStruct = 72,
|
||||
RMessageRequest = 78,
|
||||
RMessageResponse = 84,
|
||||
RMessage = 90,
|
||||
REventRequest = 98,
|
||||
REvent = 104,
|
||||
RDeclDetail = 111,
|
||||
RDecl = 118,
|
||||
Schema = 122,
|
||||
RAttributeParameter = -1,
|
||||
RAttribute = 25,
|
||||
REnumMember = 33,
|
||||
REnum = 37,
|
||||
RUnionMember = 44,
|
||||
RUnion = 48,
|
||||
RStructMember = 55,
|
||||
RStructBody = 62,
|
||||
RStruct = 68,
|
||||
RMessageRequest = 74,
|
||||
RMessageResponse = 80,
|
||||
RMessage = 86,
|
||||
REventRequest = 94,
|
||||
REvent = 100,
|
||||
RDeclDetail = 107,
|
||||
RDecl = 114,
|
||||
Schema = 118,
|
||||
};
|
||||
|
||||
const wchar_t* ParserRuleName(vl::vint index);
|
||||
|
||||
@@ -776,7 +776,7 @@ Type Declaration
|
||||
BEGIN_CLASS_MEMBER(DocumentInlineObjectRun)
|
||||
CLASS_MEMBER_BASE(DocumentContentRun)
|
||||
|
||||
CLASS_MEMBER_FIELD(size)
|
||||
CLASS_MEMBER_FIELD(sizeOverride)
|
||||
CLASS_MEMBER_FIELD(baseline)
|
||||
END_CLASS_MEMBER(DocumentInlineObjectRun)
|
||||
|
||||
|
||||
@@ -2363,6 +2363,33 @@
|
||||
}
|
||||
}],
|
||||
"type": "Struct"
|
||||
}, {
|
||||
"$ast": "StructDecl",
|
||||
"attributes": [],
|
||||
"name": "UpdateElement_DocumentParagraphResponse",
|
||||
"members": [{
|
||||
"$ast": "StructMember",
|
||||
"name": "documentSize",
|
||||
"type": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "Size"
|
||||
}
|
||||
}, {
|
||||
"$ast": "StructMember",
|
||||
"name": "inlineObjectBounds",
|
||||
"type": {
|
||||
"$ast": "MapType",
|
||||
"element": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "Rect"
|
||||
},
|
||||
"keyType": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
}
|
||||
}],
|
||||
"type": "Struct"
|
||||
}, {
|
||||
"$ast": "MessageDecl",
|
||||
"attributes": [],
|
||||
@@ -2378,7 +2405,7 @@
|
||||
"$ast": "MessageResponse",
|
||||
"type": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "Size"
|
||||
"name": "UpdateElement_DocumentParagraphResponse"
|
||||
}
|
||||
}
|
||||
}, {
|
||||
@@ -2386,6 +2413,13 @@
|
||||
"attributes": [],
|
||||
"name": "GetCaretRequest",
|
||||
"members": [{
|
||||
"$ast": "StructMember",
|
||||
"name": "id",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
}, {
|
||||
"$ast": "StructMember",
|
||||
"name": "caret",
|
||||
"type": {
|
||||
@@ -2426,6 +2460,13 @@
|
||||
"attributes": [],
|
||||
"name": "GetCaretBoundsRequest",
|
||||
"members": [{
|
||||
"$ast": "StructMember",
|
||||
"name": "id",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
}, {
|
||||
"$ast": "StructMember",
|
||||
"name": "caret",
|
||||
"type": {
|
||||
@@ -2441,11 +2482,58 @@
|
||||
}
|
||||
}],
|
||||
"type": "Struct"
|
||||
}, {
|
||||
"$ast": "StructDecl",
|
||||
"attributes": [],
|
||||
"name": "GetInlineObjectFromPointRequest",
|
||||
"members": [{
|
||||
"$ast": "StructMember",
|
||||
"name": "id",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
}, {
|
||||
"$ast": "StructMember",
|
||||
"name": "point",
|
||||
"type": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "Point"
|
||||
}
|
||||
}],
|
||||
"type": "Struct"
|
||||
}, {
|
||||
"$ast": "StructDecl",
|
||||
"attributes": [],
|
||||
"name": "IsValidCaretRequest",
|
||||
"members": [{
|
||||
"$ast": "StructMember",
|
||||
"name": "id",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
}, {
|
||||
"$ast": "StructMember",
|
||||
"name": "caret",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
}],
|
||||
"type": "Struct"
|
||||
}, {
|
||||
"$ast": "StructDecl",
|
||||
"attributes": [],
|
||||
"name": "OpenCaretRequest",
|
||||
"members": [{
|
||||
"$ast": "StructMember",
|
||||
"name": "id",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
}, {
|
||||
"$ast": "StructMember",
|
||||
"name": "caret",
|
||||
"type": {
|
||||
@@ -2512,7 +2600,7 @@
|
||||
"$ast": "MessageRequest",
|
||||
"type": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "Point"
|
||||
"name": "GetInlineObjectFromPointRequest"
|
||||
}
|
||||
},
|
||||
"response": {
|
||||
@@ -2550,8 +2638,8 @@
|
||||
"request": {
|
||||
"$ast": "MessageRequest",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
"$ast": "ReferenceType",
|
||||
"name": "IsValidCaretRequest"
|
||||
}
|
||||
},
|
||||
"response": {
|
||||
@@ -2577,7 +2665,13 @@
|
||||
"$ast": "MessageDecl",
|
||||
"attributes": [],
|
||||
"name": "DocumentParagraph_CloseCaret",
|
||||
"request": null,
|
||||
"request": {
|
||||
"$ast": "MessageRequest",
|
||||
"type": {
|
||||
"$ast": "PrimitiveType",
|
||||
"type": "Integer"
|
||||
}
|
||||
},
|
||||
"response": null
|
||||
}, {
|
||||
"$ast": "StructDecl",
|
||||
@@ -2599,20 +2693,6 @@
|
||||
}
|
||||
}],
|
||||
"type": "Struct"
|
||||
}, {
|
||||
"$ast": "EventDecl",
|
||||
"attributes": [],
|
||||
"name": "DocumentParagraph_RenderInlineObjects",
|
||||
"request": {
|
||||
"$ast": "EventRequest",
|
||||
"type": {
|
||||
"$ast": "ArrayType",
|
||||
"element": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "RenderInlineObjectRequest"
|
||||
}
|
||||
}
|
||||
}
|
||||
}, {
|
||||
"$ast": "EnumDecl",
|
||||
"attributes": [],
|
||||
@@ -3102,6 +3182,29 @@
|
||||
}
|
||||
},
|
||||
"response": null
|
||||
}, {
|
||||
"$ast": "StructDecl",
|
||||
"attributes": [],
|
||||
"name": "ElementDesc_DocumentParagraphFull",
|
||||
"members": [{
|
||||
"$ast": "StructMember",
|
||||
"name": "paragraph",
|
||||
"type": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "ElementDesc_DocumentParagraph"
|
||||
}
|
||||
}, {
|
||||
"$ast": "StructMember",
|
||||
"name": "caret",
|
||||
"type": {
|
||||
"$ast": "OptionalType",
|
||||
"element": {
|
||||
"$ast": "ReferenceType",
|
||||
"name": "OpenCaretRequest"
|
||||
}
|
||||
}
|
||||
}],
|
||||
"type": "Struct"
|
||||
}, {
|
||||
"$ast": "UnionDecl",
|
||||
"attributes": [],
|
||||
@@ -3135,7 +3238,7 @@
|
||||
"name": "ElementDesc_ImageFrame"
|
||||
}, {
|
||||
"$ast": "UnionMember",
|
||||
"name": "ElementDesc_DocumentParagraph"
|
||||
"name": "ElementDesc_DocumentParagraphFull"
|
||||
}]
|
||||
}, {
|
||||
"$ast": "StructDecl",
|
||||
|
||||
@@ -62,10 +62,17 @@ struct ElementDesc_DocumentParagraph
|
||||
var removedInlineObjects : int[];
|
||||
}
|
||||
|
||||
message RendererUpdateElement_DocumentParagraph { request: ElementDesc_DocumentParagraph; response: Size; }
|
||||
struct UpdateElement_DocumentParagraphResponse
|
||||
{
|
||||
var documentSize : Size;
|
||||
var inlineObjectBounds : Rect[int];
|
||||
}
|
||||
|
||||
message RendererUpdateElement_DocumentParagraph { request: ElementDesc_DocumentParagraph; response: UpdateElement_DocumentParagraphResponse; }
|
||||
|
||||
struct GetCaretRequest
|
||||
{
|
||||
var id : int;
|
||||
var caret : int;
|
||||
var relativePosition : CaretRelativePosition;
|
||||
}
|
||||
@@ -78,12 +85,26 @@ struct GetCaretResponse
|
||||
|
||||
struct GetCaretBoundsRequest
|
||||
{
|
||||
var id : int;
|
||||
var caret : int;
|
||||
var frontSide : bool;
|
||||
}
|
||||
|
||||
struct GetInlineObjectFromPointRequest
|
||||
{
|
||||
var id : int;
|
||||
var point : Point;
|
||||
}
|
||||
|
||||
struct IsValidCaretRequest
|
||||
{
|
||||
var id : int;
|
||||
var caret : int;
|
||||
}
|
||||
|
||||
struct OpenCaretRequest
|
||||
{
|
||||
var id : int;
|
||||
var caret : int;
|
||||
var caretColor : color;
|
||||
var frontSide : bool;
|
||||
@@ -91,16 +112,14 @@ struct OpenCaretRequest
|
||||
|
||||
message DocumentParagraph_GetCaret { request: GetCaretRequest; response: GetCaretResponse; }
|
||||
message DocumentParagraph_GetCaretBounds { request: GetCaretBoundsRequest; response: Rect; }
|
||||
message DocumentParagraph_GetInlineObjectFromPoint { request: Point; response: DocumentRun?; }
|
||||
message DocumentParagraph_GetInlineObjectFromPoint { request: GetInlineObjectFromPointRequest; response: DocumentRun?; }
|
||||
message DocumentParagraph_GetNearestCaretFromTextPos { request: GetCaretBoundsRequest; response: int; }
|
||||
message DocumentParagraph_IsValidCaret { request: int; response: bool; }
|
||||
message DocumentParagraph_IsValidCaret { request: IsValidCaretRequest; response: bool; }
|
||||
message DocumentParagraph_OpenCaret { request: OpenCaretRequest; }
|
||||
message DocumentParagraph_CloseCaret {}
|
||||
message DocumentParagraph_CloseCaret { request: int; }
|
||||
|
||||
struct RenderInlineObjectRequest
|
||||
{
|
||||
var callbackId : int;
|
||||
var location : Rect;
|
||||
}
|
||||
|
||||
event DocumentParagraph_RenderInlineObjects { request: RenderInlineObjectRequest[]; }
|
||||
}
|
||||
@@ -1,3 +1,9 @@
|
||||
struct ElementDesc_DocumentParagraphFull
|
||||
{
|
||||
var paragraph : ElementDesc_DocumentParagraph;
|
||||
var caret : OpenCaretRequest?;
|
||||
}
|
||||
|
||||
union UnitTest_ElementDescVariant
|
||||
{
|
||||
ElementDesc_SolidBorder,
|
||||
@@ -9,7 +15,7 @@ union UnitTest_ElementDescVariant
|
||||
ElementDesc_Polygon,
|
||||
ElementDesc_SolidLabel,
|
||||
ElementDesc_ImageFrame,
|
||||
ElementDesc_DocumentParagraph,
|
||||
ElementDesc_DocumentParagraphFull,
|
||||
}
|
||||
|
||||
struct UnitTest_RenderingFrame
|
||||
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Reference in New Issue
Block a user