mirror of
https://github.com/nomic-ai/gpt4all
synced 2024-11-10 01:10:35 +00:00
Fix response generation which was broken by themeable syntax highlighting. (#2494)
Signed-off-by: Adam Treat <treat.adam@gmail.com>
This commit is contained in:
parent
ab46bd5739
commit
56834a28cb
@ -188,6 +188,11 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Q_INVOKABLE void forceUpdate(int index)
|
||||||
|
{
|
||||||
|
emit dataChanged(createIndex(index, 0), createIndex(index, 0), {ValueRole});
|
||||||
|
}
|
||||||
|
|
||||||
Q_INVOKABLE void updateValue(int index, const QString &value)
|
Q_INVOKABLE void updateValue(int index, const QString &value)
|
||||||
{
|
{
|
||||||
if (index < 0 || index >= m_chatItems.size()) return;
|
if (index < 0 || index >= m_chatItems.size()) return;
|
||||||
|
@ -966,7 +966,7 @@ Rectangle {
|
|||||||
textProcessor.codeColors.headerColor = theme.codeHeaderColor
|
textProcessor.codeColors.headerColor = theme.codeHeaderColor
|
||||||
textProcessor.codeColors.backgroundColor = theme.codeBackgroundColor
|
textProcessor.codeColors.backgroundColor = theme.codeBackgroundColor
|
||||||
textProcessor.textDocument = textDocument
|
textProcessor.textDocument = textDocument
|
||||||
myTextArea.text = value
|
chatModel.forceUpdate(index); // called to trigger a reprocessing of the text
|
||||||
}
|
}
|
||||||
|
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
|
Loading…
Reference in New Issue
Block a user